Imported Upstream version 1.9.2
Markus Koschany
11 years ago
159 | 159 | DEFAULT_UDP_SERVER_PORT = @DEFAULT_UDP_SERVER_PORT@ |
160 | 160 | DEFS = @DEFS@ |
161 | 161 | DEPDIR = @DEPDIR@ |
162 | DLLTOOL = @DLLTOOL@ | |
162 | 163 | DSYMUTIL = @DSYMUTIL@ |
163 | 164 | DUMPBIN = @DUMPBIN@ |
164 | 165 | ECHO_C = @ECHO_C@ |
184 | 185 | LN_S = @LN_S@ |
185 | 186 | LTLIBOBJS = @LTLIBOBJS@ |
186 | 187 | MAKEINFO = @MAKEINFO@ |
188 | MANIFEST_TOOL = @MANIFEST_TOOL@ | |
187 | 189 | MANUAL_DATE_EN = @MANUAL_DATE_EN@ |
188 | 190 | MANUAL_DATE_FR = @MANUAL_DATE_FR@ |
189 | 191 | MINVER_FLATZEBRA = @MINVER_FLATZEBRA@ |
218 | 220 | abs_srcdir = @abs_srcdir@ |
219 | 221 | abs_top_builddir = @abs_top_builddir@ |
220 | 222 | abs_top_srcdir = @abs_top_srcdir@ |
223 | ac_ct_AR = @ac_ct_AR@ | |
221 | 224 | ac_ct_CC = @ac_ct_CC@ |
222 | 225 | ac_ct_CXX = @ac_ct_CXX@ |
223 | 226 | ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ |
0 | 2013-02-25: Version 1.9.2 released | |
1 | ||
2 | Slot selection when loading or saving games can now be done | |
3 | with up and down keys, to accommodate keyboard layouts where | |
4 | digits are shifted. | |
5 | Fixed bug where program crashed when saving game where | |
6 | player sprite was absent. Saved format version changed, | |
7 | but version 1 format can still be loaded. | |
8 | Added #include <unistd.h> to src/RemoteServer.cpp to resolve | |
9 | a compilation error related to close(1) under GCC 4.7. | |
10 | Fixed default UDP port displayed by ./configure --help. | |
11 | ||
0 | 12 | 2012-07-14: Version 1.9.1 released |
1 | 13 | |
2 | 14 | Now links with version 0.1.6 of flatzebra library. |
0 | 0 | BurgerSpace - A hamburger-smashing video game. |
1 | 1 | |
2 | Copyright (C) 2001-2010 Pierre Sarrazin <http://sarrazip.com/> | |
2 | Copyright (C) 2001-2013 Pierre Sarrazin <http://sarrazip.com/> | |
3 | 3 | This program is free software distributed under the GNU GPL. |
4 | 4 | See the file COPYING. |
5 | 5 |
0 | 0 | Name: burgerspace |
1 | Version: 1.9.1 | |
1 | Version: 1.9.2 | |
2 | 2 | Release: 1%{?dist} |
3 | 3 | Summary: A hamburger-smashing video game |
4 | 4 | Summary(fr): Un jeu de hamburgers qu'on écrase |
16 | 16 | BurgerSpace is a game in which you are a chef who must walk |
17 | 17 | over hamburger parts (buns, meat, lettuce, etc) to make them fall from |
18 | 18 | floor to floor, until they end up on the plates at the bottom of the |
19 | screen. | |
19 | screen. It is a clone of the 1982 BurgerTime video game by Data East. | |
20 | 20 | |
21 | 21 | %description -l fr |
22 | 22 | BurgerSpace est un jeu où vous êtes un chef qui doit marcher |
23 | 23 | sur des tranches de hamburger (pain, viande, laitue, etc) pour |
24 | 24 | les faire tomber d'étage en étage, jusqu'à ce qu'ils se retrouvent |
25 | dans les assiettes au bas de l'écran. | |
25 | dans les assiettes au bas de l'écran. Il s'agit d'un clone du jeu | |
26 | BurgerTime créé par Data East en 1982. | |
26 | 27 | |
27 | 28 | %prep |
28 | 29 | %setup -q |
16 | 16 | @PACKAGE_FULL_NAME@ is a game in which you are a chef who must walk |
17 | 17 | over hamburger parts (buns, meat, lettuce, etc) to make them fall from |
18 | 18 | floor to floor, until they end up on the plates at the bottom of the |
19 | screen. | |
19 | screen. It is a clone of the 1982 BurgerTime video game by Data East. | |
20 | 20 | |
21 | 21 | %description -l fr |
22 | 22 | @PACKAGE_FULL_NAME@ est un jeu où vous êtes un chef qui doit marcher |
23 | 23 | sur des tranches de hamburger (pain, viande, laitue, etc) pour |
24 | 24 | les faire tomber d'étage en étage, jusqu'à ce qu'ils se retrouvent |
25 | dans les assiettes au bas de l'écran. | |
25 | dans les assiettes au bas de l'écran. Il s'agit d'un clone du jeu | |
26 | BurgerTime créé par Data East en 1982. | |
26 | 27 | |
27 | 28 | %prep |
28 | 29 | %setup -q |
636 | 636 | LIPO |
637 | 637 | NMEDIT |
638 | 638 | DSYMUTIL |
639 | MANIFEST_TOOL | |
639 | 640 | RANLIB |
641 | ac_ct_AR | |
640 | 642 | AR |
643 | DLLTOOL | |
641 | 644 | OBJDUMP |
642 | 645 | LN_S |
643 | 646 | NM |
752 | 755 | enable_fast_install |
753 | 756 | enable_dependency_tracking |
754 | 757 | with_gnu_ld |
758 | with_sysroot | |
755 | 759 | enable_libtool_lock |
756 | 760 | with_network |
757 | 761 | with_default_udp_port |
1407 | 1411 | --with-pic try to use only PIC/non-PIC objects [default=use |
1408 | 1412 | both] |
1409 | 1413 | --with-gnu-ld assume the C compiler uses GNU ld [default=no] |
1414 | --with-sysroot=DIR Search for dependent libraries within DIR | |
1415 | (or the compiler's sysroot if not specified). | |
1410 | 1416 | --with-network build network (client-server) version (default: yes) |
1411 | --with-default-udp-port default UDP port number on which to accept clients (default: $DEFAULT_UDP_SERVER_PORT) | |
1417 | --with-default-udp-port default UDP port number on which to accept clients (default: 49152) | |
1412 | 1418 | |
1413 | 1419 | Some influential environment variables: |
1414 | 1420 | CC C compiler command |
2977 | 2983 | |
2978 | 2984 | # Define the identity of the package. |
2979 | 2985 | PACKAGE=burgerspace |
2980 | VERSION=1.9.1 | |
2986 | VERSION=1.9.2 | |
2981 | 2987 | |
2982 | 2988 | |
2983 | 2989 | cat >>confdefs.h <<_ACEOF |
3018 | 3024 | |
3019 | 3025 | |
3020 | 3026 | |
3021 | MANUAL_DATE_EN="July 14th, 2012"; | |
3022 | MANUAL_DATE_FR="14 juillet 2012"; # UTF-8 | |
3027 | MANUAL_DATE_EN="February 25th, 2013"; | |
3028 | MANUAL_DATE_FR="25 février 2013"; # UTF-8 | |
3023 | 3029 | |
3024 | 3030 | PACKAGE_FULL_NAME="BurgerSpace" |
3025 | 3031 | PACKAGE_SUMMARY_EN="A hamburger-smashing video game" |
3068 | 3074 | |
3069 | 3075 | |
3070 | 3076 | |
3071 | macro_version='2.2.10' | |
3072 | macro_revision='1.3175' | |
3077 | macro_version='2.4' | |
3078 | macro_revision='1.3293' | |
3073 | 3079 | |
3074 | 3080 | |
3075 | 3081 | |
3109 | 3115 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 |
3110 | 3116 | $as_echo_n "checking how to print strings... " >&6; } |
3111 | 3117 | # Test print first, because it will be a builtin if present. |
3112 | if test "X`print -r -- -n 2>/dev/null`" = X-n && \ | |
3118 | if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ | |
3113 | 3119 | test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then |
3114 | 3120 | ECHO='print -r --' |
3115 | 3121 | elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then |
4904 | 4910 | # Try some XSI features |
4905 | 4911 | xsi_shell=no |
4906 | 4912 | ( _lt_dummy="a/b/c" |
4907 | test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \ | |
4908 | = c,a/b,, \ | |
4913 | test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ | |
4914 | = c,a/b,b/c, \ | |
4909 | 4915 | && eval 'test $(( 1 + 1 )) -eq 2 \ |
4910 | 4916 | && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ |
4911 | 4917 | && xsi_shell=yes |
4954 | 4960 | |
4955 | 4961 | |
4956 | 4962 | |
4963 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 | |
4964 | $as_echo_n "checking how to convert $build file names to $host format... " >&6; } | |
4965 | if ${lt_cv_to_host_file_cmd+:} false; then : | |
4966 | $as_echo_n "(cached) " >&6 | |
4967 | else | |
4968 | case $host in | |
4969 | *-*-mingw* ) | |
4970 | case $build in | |
4971 | *-*-mingw* ) # actually msys | |
4972 | lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 | |
4973 | ;; | |
4974 | *-*-cygwin* ) | |
4975 | lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 | |
4976 | ;; | |
4977 | * ) # otherwise, assume *nix | |
4978 | lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 | |
4979 | ;; | |
4980 | esac | |
4981 | ;; | |
4982 | *-*-cygwin* ) | |
4983 | case $build in | |
4984 | *-*-mingw* ) # actually msys | |
4985 | lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin | |
4986 | ;; | |
4987 | *-*-cygwin* ) | |
4988 | lt_cv_to_host_file_cmd=func_convert_file_noop | |
4989 | ;; | |
4990 | * ) # otherwise, assume *nix | |
4991 | lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin | |
4992 | ;; | |
4993 | esac | |
4994 | ;; | |
4995 | * ) # unhandled hosts (and "normal" native builds) | |
4996 | lt_cv_to_host_file_cmd=func_convert_file_noop | |
4997 | ;; | |
4998 | esac | |
4999 | ||
5000 | fi | |
5001 | ||
5002 | to_host_file_cmd=$lt_cv_to_host_file_cmd | |
5003 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 | |
5004 | $as_echo "$lt_cv_to_host_file_cmd" >&6; } | |
5005 | ||
5006 | ||
5007 | ||
5008 | ||
5009 | ||
5010 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 | |
5011 | $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } | |
5012 | if ${lt_cv_to_tool_file_cmd+:} false; then : | |
5013 | $as_echo_n "(cached) " >&6 | |
5014 | else | |
5015 | #assume ordinary cross tools, or native build. | |
5016 | lt_cv_to_tool_file_cmd=func_convert_file_noop | |
5017 | case $host in | |
5018 | *-*-mingw* ) | |
5019 | case $build in | |
5020 | *-*-mingw* ) # actually msys | |
5021 | lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 | |
5022 | ;; | |
5023 | esac | |
5024 | ;; | |
5025 | esac | |
5026 | ||
5027 | fi | |
5028 | ||
5029 | to_tool_file_cmd=$lt_cv_to_tool_file_cmd | |
5030 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 | |
5031 | $as_echo "$lt_cv_to_tool_file_cmd" >&6; } | |
5032 | ||
5033 | ||
5034 | ||
5035 | ||
5036 | ||
4957 | 5037 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 |
4958 | 5038 | $as_echo_n "checking for $LD option to reload object files... " >&6; } |
4959 | 5039 | if ${lt_cv_ld_reload_flag+:} false; then : |
4970 | 5050 | esac |
4971 | 5051 | reload_cmds='$LD$reload_flag -o $output$reload_objs' |
4972 | 5052 | case $host_os in |
5053 | cygwin* | mingw* | pw32* | cegcc*) | |
5054 | if test "$GCC" != yes; then | |
5055 | reload_cmds=false | |
5056 | fi | |
5057 | ;; | |
4973 | 5058 | darwin*) |
4974 | 5059 | if test "$GCC" = yes; then |
4975 | 5060 | reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' |
5293 | 5378 | fi |
5294 | 5379 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 |
5295 | 5380 | $as_echo "$lt_cv_deplibs_check_method" >&6; } |
5381 | ||
5382 | file_magic_glob= | |
5383 | want_nocaseglob=no | |
5384 | if test "$build" = "$host"; then | |
5385 | case $host_os in | |
5386 | mingw* | pw32*) | |
5387 | if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then | |
5388 | want_nocaseglob=yes | |
5389 | else | |
5390 | file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` | |
5391 | fi | |
5392 | ;; | |
5393 | esac | |
5394 | fi | |
5395 | ||
5296 | 5396 | file_magic_cmd=$lt_cv_file_magic_cmd |
5297 | 5397 | deplibs_check_method=$lt_cv_deplibs_check_method |
5298 | 5398 | test -z "$deplibs_check_method" && deplibs_check_method=unknown |
5308 | 5408 | |
5309 | 5409 | |
5310 | 5410 | |
5411 | ||
5412 | ||
5413 | ||
5414 | ||
5415 | ||
5416 | ||
5417 | ||
5418 | ||
5419 | ||
5420 | ||
5311 | 5421 | if test -n "$ac_tool_prefix"; then |
5312 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. | |
5313 | set dummy ${ac_tool_prefix}ar; ac_word=$2 | |
5422 | # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. | |
5423 | set dummy ${ac_tool_prefix}dlltool; ac_word=$2 | |
5314 | 5424 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
5315 | 5425 | $as_echo_n "checking for $ac_word... " >&6; } |
5316 | if ${ac_cv_prog_AR+:} false; then : | |
5426 | if ${ac_cv_prog_DLLTOOL+:} false; then : | |
5317 | 5427 | $as_echo_n "(cached) " >&6 |
5318 | 5428 | else |
5319 | if test -n "$AR"; then | |
5320 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
5429 | if test -n "$DLLTOOL"; then | |
5430 | ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. | |
5321 | 5431 | else |
5322 | 5432 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5323 | 5433 | for as_dir in $PATH |
5326 | 5436 | test -z "$as_dir" && as_dir=. |
5327 | 5437 | for ac_exec_ext in '' $ac_executable_extensions; do |
5328 | 5438 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
5329 | ac_cv_prog_AR="${ac_tool_prefix}ar" | |
5439 | ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" | |
5330 | 5440 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5331 | 5441 | break 2 |
5332 | 5442 | fi |
5336 | 5446 | |
5337 | 5447 | fi |
5338 | 5448 | fi |
5339 | AR=$ac_cv_prog_AR | |
5340 | if test -n "$AR"; then | |
5341 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 | |
5342 | $as_echo "$AR" >&6; } | |
5449 | DLLTOOL=$ac_cv_prog_DLLTOOL | |
5450 | if test -n "$DLLTOOL"; then | |
5451 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 | |
5452 | $as_echo "$DLLTOOL" >&6; } | |
5343 | 5453 | else |
5344 | 5454 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
5345 | 5455 | $as_echo "no" >&6; } |
5347 | 5457 | |
5348 | 5458 | |
5349 | 5459 | fi |
5350 | if test -z "$ac_cv_prog_AR"; then | |
5351 | ac_ct_AR=$AR | |
5352 | # Extract the first word of "ar", so it can be a program name with args. | |
5353 | set dummy ar; ac_word=$2 | |
5460 | if test -z "$ac_cv_prog_DLLTOOL"; then | |
5461 | ac_ct_DLLTOOL=$DLLTOOL | |
5462 | # Extract the first word of "dlltool", so it can be a program name with args. | |
5463 | set dummy dlltool; ac_word=$2 | |
5354 | 5464 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
5355 | 5465 | $as_echo_n "checking for $ac_word... " >&6; } |
5356 | if ${ac_cv_prog_ac_ct_AR+:} false; then : | |
5466 | if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : | |
5357 | 5467 | $as_echo_n "(cached) " >&6 |
5358 | 5468 | else |
5359 | if test -n "$ac_ct_AR"; then | |
5360 | ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. | |
5469 | if test -n "$ac_ct_DLLTOOL"; then | |
5470 | ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. | |
5361 | 5471 | else |
5362 | 5472 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5363 | 5473 | for as_dir in $PATH |
5366 | 5476 | test -z "$as_dir" && as_dir=. |
5367 | 5477 | for ac_exec_ext in '' $ac_executable_extensions; do |
5368 | 5478 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
5369 | ac_cv_prog_ac_ct_AR="ar" | |
5479 | ac_cv_prog_ac_ct_DLLTOOL="dlltool" | |
5370 | 5480 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5371 | 5481 | break 2 |
5372 | 5482 | fi |
5376 | 5486 | |
5377 | 5487 | fi |
5378 | 5488 | fi |
5489 | ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL | |
5490 | if test -n "$ac_ct_DLLTOOL"; then | |
5491 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 | |
5492 | $as_echo "$ac_ct_DLLTOOL" >&6; } | |
5493 | else | |
5494 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
5495 | $as_echo "no" >&6; } | |
5496 | fi | |
5497 | ||
5498 | if test "x$ac_ct_DLLTOOL" = x; then | |
5499 | DLLTOOL="false" | |
5500 | else | |
5501 | case $cross_compiling:$ac_tool_warned in | |
5502 | yes:) | |
5503 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
5504 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
5505 | ac_tool_warned=yes ;; | |
5506 | esac | |
5507 | DLLTOOL=$ac_ct_DLLTOOL | |
5508 | fi | |
5509 | else | |
5510 | DLLTOOL="$ac_cv_prog_DLLTOOL" | |
5511 | fi | |
5512 | ||
5513 | test -z "$DLLTOOL" && DLLTOOL=dlltool | |
5514 | ||
5515 | ||
5516 | ||
5517 | ||
5518 | ||
5519 | ||
5520 | ||
5521 | ||
5522 | ||
5523 | ||
5524 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 | |
5525 | $as_echo_n "checking how to associate runtime and link libraries... " >&6; } | |
5526 | if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : | |
5527 | $as_echo_n "(cached) " >&6 | |
5528 | else | |
5529 | lt_cv_sharedlib_from_linklib_cmd='unknown' | |
5530 | ||
5531 | case $host_os in | |
5532 | cygwin* | mingw* | pw32* | cegcc*) | |
5533 | # two different shell functions defined in ltmain.sh | |
5534 | # decide which to use based on capabilities of $DLLTOOL | |
5535 | case `$DLLTOOL --help 2>&1` in | |
5536 | *--identify-strict*) | |
5537 | lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib | |
5538 | ;; | |
5539 | *) | |
5540 | lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback | |
5541 | ;; | |
5542 | esac | |
5543 | ;; | |
5544 | *) | |
5545 | # fallback: assume linklib IS sharedlib | |
5546 | lt_cv_sharedlib_from_linklib_cmd="$ECHO" | |
5547 | ;; | |
5548 | esac | |
5549 | ||
5550 | fi | |
5551 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 | |
5552 | $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } | |
5553 | sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd | |
5554 | test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO | |
5555 | ||
5556 | ||
5557 | ||
5558 | ||
5559 | ||
5560 | ||
5561 | ||
5562 | ||
5563 | if test -n "$ac_tool_prefix"; then | |
5564 | for ac_prog in ar | |
5565 | do | |
5566 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. | |
5567 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 | |
5568 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
5569 | $as_echo_n "checking for $ac_word... " >&6; } | |
5570 | if ${ac_cv_prog_AR+:} false; then : | |
5571 | $as_echo_n "(cached) " >&6 | |
5572 | else | |
5573 | if test -n "$AR"; then | |
5574 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
5575 | else | |
5576 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
5577 | for as_dir in $PATH | |
5578 | do | |
5579 | IFS=$as_save_IFS | |
5580 | test -z "$as_dir" && as_dir=. | |
5581 | for ac_exec_ext in '' $ac_executable_extensions; do | |
5582 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5583 | ac_cv_prog_AR="$ac_tool_prefix$ac_prog" | |
5584 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
5585 | break 2 | |
5586 | fi | |
5587 | done | |
5588 | done | |
5589 | IFS=$as_save_IFS | |
5590 | ||
5591 | fi | |
5592 | fi | |
5593 | AR=$ac_cv_prog_AR | |
5594 | if test -n "$AR"; then | |
5595 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 | |
5596 | $as_echo "$AR" >&6; } | |
5597 | else | |
5598 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
5599 | $as_echo "no" >&6; } | |
5600 | fi | |
5601 | ||
5602 | ||
5603 | test -n "$AR" && break | |
5604 | done | |
5605 | fi | |
5606 | if test -z "$AR"; then | |
5607 | ac_ct_AR=$AR | |
5608 | for ac_prog in ar | |
5609 | do | |
5610 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
5611 | set dummy $ac_prog; ac_word=$2 | |
5612 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
5613 | $as_echo_n "checking for $ac_word... " >&6; } | |
5614 | if ${ac_cv_prog_ac_ct_AR+:} false; then : | |
5615 | $as_echo_n "(cached) " >&6 | |
5616 | else | |
5617 | if test -n "$ac_ct_AR"; then | |
5618 | ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. | |
5619 | else | |
5620 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
5621 | for as_dir in $PATH | |
5622 | do | |
5623 | IFS=$as_save_IFS | |
5624 | test -z "$as_dir" && as_dir=. | |
5625 | for ac_exec_ext in '' $ac_executable_extensions; do | |
5626 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5627 | ac_cv_prog_ac_ct_AR="$ac_prog" | |
5628 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
5629 | break 2 | |
5630 | fi | |
5631 | done | |
5632 | done | |
5633 | IFS=$as_save_IFS | |
5634 | ||
5635 | fi | |
5636 | fi | |
5379 | 5637 | ac_ct_AR=$ac_cv_prog_ac_ct_AR |
5380 | 5638 | if test -n "$ac_ct_AR"; then |
5381 | 5639 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 |
5384 | 5642 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
5385 | 5643 | $as_echo "no" >&6; } |
5386 | 5644 | fi |
5645 | ||
5646 | ||
5647 | test -n "$ac_ct_AR" && break | |
5648 | done | |
5387 | 5649 | |
5388 | 5650 | if test "x$ac_ct_AR" = x; then |
5389 | 5651 | AR="false" |
5396 | 5658 | esac |
5397 | 5659 | AR=$ac_ct_AR |
5398 | 5660 | fi |
5399 | else | |
5400 | AR="$ac_cv_prog_AR" | |
5401 | fi | |
5402 | ||
5403 | test -z "$AR" && AR=ar | |
5404 | test -z "$AR_FLAGS" && AR_FLAGS=cru | |
5405 | ||
5406 | ||
5407 | ||
5408 | ||
5661 | fi | |
5662 | ||
5663 | : ${AR=ar} | |
5664 | : ${AR_FLAGS=cru} | |
5665 | ||
5666 | ||
5667 | ||
5668 | ||
5669 | ||
5670 | ||
5671 | ||
5672 | ||
5673 | ||
5674 | ||
5675 | ||
5676 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 | |
5677 | $as_echo_n "checking for archiver @FILE support... " >&6; } | |
5678 | if ${lt_cv_ar_at_file+:} false; then : | |
5679 | $as_echo_n "(cached) " >&6 | |
5680 | else | |
5681 | lt_cv_ar_at_file=no | |
5682 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5683 | /* end confdefs.h. */ | |
5684 | ||
5685 | int | |
5686 | main () | |
5687 | { | |
5688 | ||
5689 | ; | |
5690 | return 0; | |
5691 | } | |
5692 | _ACEOF | |
5693 | if ac_fn_c_try_compile "$LINENO"; then : | |
5694 | echo conftest.$ac_objext > conftest.lst | |
5695 | lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' | |
5696 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 | |
5697 | (eval $lt_ar_try) 2>&5 | |
5698 | ac_status=$? | |
5699 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
5700 | test $ac_status = 0; } | |
5701 | if test "$ac_status" -eq 0; then | |
5702 | # Ensure the archiver fails upon bogus file names. | |
5703 | rm -f conftest.$ac_objext libconftest.a | |
5704 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 | |
5705 | (eval $lt_ar_try) 2>&5 | |
5706 | ac_status=$? | |
5707 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
5708 | test $ac_status = 0; } | |
5709 | if test "$ac_status" -ne 0; then | |
5710 | lt_cv_ar_at_file=@ | |
5711 | fi | |
5712 | fi | |
5713 | rm -f conftest.* libconftest.a | |
5714 | ||
5715 | fi | |
5716 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5717 | ||
5718 | fi | |
5719 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 | |
5720 | $as_echo "$lt_cv_ar_at_file" >&6; } | |
5721 | ||
5722 | if test "x$lt_cv_ar_at_file" = xno; then | |
5723 | archiver_list_spec= | |
5724 | else | |
5725 | archiver_list_spec=$lt_cv_ar_at_file | |
5726 | fi | |
5409 | 5727 | |
5410 | 5728 | |
5411 | 5729 | |
5747 | 6065 | lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" |
5748 | 6066 | |
5749 | 6067 | # Transform an extracted symbol line into symbol name and symbol address |
5750 | lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'" | |
5751 | lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'" | |
6068 | lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'" | |
6069 | lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'" | |
5752 | 6070 | |
5753 | 6071 | # Handle CRLF in mingw tool chain |
5754 | 6072 | opt_cr= |
5784 | 6102 | else |
5785 | 6103 | lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" |
5786 | 6104 | fi |
6105 | lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" | |
5787 | 6106 | |
5788 | 6107 | # Check to see that the pipe works correctly. |
5789 | 6108 | pipe_works=no |
5825 | 6144 | if $GREP ' nm_test_var$' "$nlist" >/dev/null; then |
5826 | 6145 | if $GREP ' nm_test_func$' "$nlist" >/dev/null; then |
5827 | 6146 | cat <<_LT_EOF > conftest.$ac_ext |
6147 | /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ | |
6148 | #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) | |
6149 | /* DATA imports from DLLs on WIN32 con't be const, because runtime | |
6150 | relocations are performed -- see ld's documentation on pseudo-relocs. */ | |
6151 | # define LT_DLSYM_CONST | |
6152 | #elif defined(__osf__) | |
6153 | /* This system does not cope well with relocations in const data. */ | |
6154 | # define LT_DLSYM_CONST | |
6155 | #else | |
6156 | # define LT_DLSYM_CONST const | |
6157 | #endif | |
6158 | ||
5828 | 6159 | #ifdef __cplusplus |
5829 | 6160 | extern "C" { |
5830 | 6161 | #endif |
5836 | 6167 | cat <<_LT_EOF >> conftest.$ac_ext |
5837 | 6168 | |
5838 | 6169 | /* The mapping between symbol names and symbols. */ |
5839 | const struct { | |
6170 | LT_DLSYM_CONST struct { | |
5840 | 6171 | const char *name; |
5841 | 6172 | void *address; |
5842 | 6173 | } |
5862 | 6193 | _LT_EOF |
5863 | 6194 | # Now try linking the two files. |
5864 | 6195 | mv conftest.$ac_objext conftstm.$ac_objext |
5865 | lt_save_LIBS="$LIBS" | |
5866 | lt_save_CFLAGS="$CFLAGS" | |
6196 | lt_globsym_save_LIBS=$LIBS | |
6197 | lt_globsym_save_CFLAGS=$CFLAGS | |
5867 | 6198 | LIBS="conftstm.$ac_objext" |
5868 | 6199 | CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" |
5869 | 6200 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 |
5873 | 6204 | test $ac_status = 0; } && test -s conftest${ac_exeext}; then |
5874 | 6205 | pipe_works=yes |
5875 | 6206 | fi |
5876 | LIBS="$lt_save_LIBS" | |
5877 | CFLAGS="$lt_save_CFLAGS" | |
6207 | LIBS=$lt_globsym_save_LIBS | |
6208 | CFLAGS=$lt_globsym_save_CFLAGS | |
5878 | 6209 | else |
5879 | 6210 | echo "cannot find nm_test_func in $nlist" >&5 |
5880 | 6211 | fi |
5911 | 6242 | $as_echo "ok" >&6; } |
5912 | 6243 | fi |
5913 | 6244 | |
5914 | ||
5915 | ||
5916 | ||
5917 | ||
5918 | ||
5919 | ||
5920 | ||
5921 | ||
5922 | ||
5923 | ||
5924 | ||
5925 | ||
5926 | ||
5927 | ||
5928 | ||
5929 | ||
5930 | ||
6245 | # Response file support. | |
6246 | if test "$lt_cv_nm_interface" = "MS dumpbin"; then | |
6247 | nm_file_list_spec='@' | |
6248 | elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then | |
6249 | nm_file_list_spec='@' | |
6250 | fi | |
6251 | ||
6252 | ||
6253 | ||
6254 | ||
6255 | ||
6256 | ||
6257 | ||
6258 | ||
6259 | ||
6260 | ||
6261 | ||
6262 | ||
6263 | ||
6264 | ||
6265 | ||
6266 | ||
6267 | ||
6268 | ||
6269 | ||
6270 | ||
6271 | ||
6272 | ||
6273 | ||
6274 | ||
6275 | ||
6276 | ||
6277 | ||
6278 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 | |
6279 | $as_echo_n "checking for sysroot... " >&6; } | |
6280 | ||
6281 | # Check whether --with-sysroot was given. | |
6282 | if test "${with_sysroot+set}" = set; then : | |
6283 | withval=$with_sysroot; | |
6284 | else | |
6285 | with_sysroot=no | |
6286 | fi | |
6287 | ||
6288 | ||
6289 | lt_sysroot= | |
6290 | case ${with_sysroot} in #( | |
6291 | yes) | |
6292 | if test "$GCC" = yes; then | |
6293 | lt_sysroot=`$CC --print-sysroot 2>/dev/null` | |
6294 | fi | |
6295 | ;; #( | |
6296 | /*) | |
6297 | lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` | |
6298 | ;; #( | |
6299 | no|'') | |
6300 | ;; #( | |
6301 | *) | |
6302 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5 | |
6303 | $as_echo "${with_sysroot}" >&6; } | |
6304 | as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 | |
6305 | ;; | |
6306 | esac | |
6307 | ||
6308 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 | |
6309 | $as_echo "${lt_sysroot:-no}" >&6; } | |
5931 | 6310 | |
5932 | 6311 | |
5933 | 6312 | |
6126 | 6505 | |
6127 | 6506 | need_locks="$enable_libtool_lock" |
6128 | 6507 | |
6508 | if test -n "$ac_tool_prefix"; then | |
6509 | # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. | |
6510 | set dummy ${ac_tool_prefix}mt; ac_word=$2 | |
6511 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
6512 | $as_echo_n "checking for $ac_word... " >&6; } | |
6513 | if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : | |
6514 | $as_echo_n "(cached) " >&6 | |
6515 | else | |
6516 | if test -n "$MANIFEST_TOOL"; then | |
6517 | ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. | |
6518 | else | |
6519 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
6520 | for as_dir in $PATH | |
6521 | do | |
6522 | IFS=$as_save_IFS | |
6523 | test -z "$as_dir" && as_dir=. | |
6524 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6525 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
6526 | ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" | |
6527 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
6528 | break 2 | |
6529 | fi | |
6530 | done | |
6531 | done | |
6532 | IFS=$as_save_IFS | |
6533 | ||
6534 | fi | |
6535 | fi | |
6536 | MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL | |
6537 | if test -n "$MANIFEST_TOOL"; then | |
6538 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 | |
6539 | $as_echo "$MANIFEST_TOOL" >&6; } | |
6540 | else | |
6541 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
6542 | $as_echo "no" >&6; } | |
6543 | fi | |
6544 | ||
6545 | ||
6546 | fi | |
6547 | if test -z "$ac_cv_prog_MANIFEST_TOOL"; then | |
6548 | ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL | |
6549 | # Extract the first word of "mt", so it can be a program name with args. | |
6550 | set dummy mt; ac_word=$2 | |
6551 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
6552 | $as_echo_n "checking for $ac_word... " >&6; } | |
6553 | if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : | |
6554 | $as_echo_n "(cached) " >&6 | |
6555 | else | |
6556 | if test -n "$ac_ct_MANIFEST_TOOL"; then | |
6557 | ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. | |
6558 | else | |
6559 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
6560 | for as_dir in $PATH | |
6561 | do | |
6562 | IFS=$as_save_IFS | |
6563 | test -z "$as_dir" && as_dir=. | |
6564 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6565 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
6566 | ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" | |
6567 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
6568 | break 2 | |
6569 | fi | |
6570 | done | |
6571 | done | |
6572 | IFS=$as_save_IFS | |
6573 | ||
6574 | fi | |
6575 | fi | |
6576 | ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL | |
6577 | if test -n "$ac_ct_MANIFEST_TOOL"; then | |
6578 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 | |
6579 | $as_echo "$ac_ct_MANIFEST_TOOL" >&6; } | |
6580 | else | |
6581 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
6582 | $as_echo "no" >&6; } | |
6583 | fi | |
6584 | ||
6585 | if test "x$ac_ct_MANIFEST_TOOL" = x; then | |
6586 | MANIFEST_TOOL=":" | |
6587 | else | |
6588 | case $cross_compiling:$ac_tool_warned in | |
6589 | yes:) | |
6590 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
6591 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
6592 | ac_tool_warned=yes ;; | |
6593 | esac | |
6594 | MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL | |
6595 | fi | |
6596 | else | |
6597 | MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" | |
6598 | fi | |
6599 | ||
6600 | test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt | |
6601 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 | |
6602 | $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } | |
6603 | if ${lt_cv_path_mainfest_tool+:} false; then : | |
6604 | $as_echo_n "(cached) " >&6 | |
6605 | else | |
6606 | lt_cv_path_mainfest_tool=no | |
6607 | echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 | |
6608 | $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out | |
6609 | cat conftest.err >&5 | |
6610 | if $GREP 'Manifest Tool' conftest.out > /dev/null; then | |
6611 | lt_cv_path_mainfest_tool=yes | |
6612 | fi | |
6613 | rm -f conftest* | |
6614 | fi | |
6615 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 | |
6616 | $as_echo "$lt_cv_path_mainfest_tool" >&6; } | |
6617 | if test "x$lt_cv_path_mainfest_tool" != xyes; then | |
6618 | MANIFEST_TOOL=: | |
6619 | fi | |
6620 | ||
6621 | ||
6622 | ||
6623 | ||
6624 | ||
6129 | 6625 | |
6130 | 6626 | case $host_os in |
6131 | 6627 | rhapsody* | darwin*) |
7510 | 8006 | lt_prog_compiler_pic= |
7511 | 8007 | lt_prog_compiler_static= |
7512 | 8008 | |
7513 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 | |
7514 | $as_echo_n "checking for $compiler option to produce PIC... " >&6; } | |
7515 | 8009 | |
7516 | 8010 | if test "$GCC" = yes; then |
7517 | 8011 | lt_prog_compiler_wl='-Wl,' |
7675 | 8169 | lt_prog_compiler_wl='-Wl,' |
7676 | 8170 | lt_prog_compiler_pic='--shared' |
7677 | 8171 | lt_prog_compiler_static='--static' |
8172 | ;; | |
8173 | nagfor*) | |
8174 | # NAG Fortran compiler | |
8175 | lt_prog_compiler_wl='-Wl,-Wl,,' | |
8176 | lt_prog_compiler_pic='-PIC' | |
8177 | lt_prog_compiler_static='-Bstatic' | |
7678 | 8178 | ;; |
7679 | 8179 | pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) |
7680 | 8180 | # Portland Group compilers (*not* the Pentium gcc compiler, |
7795 | 8295 | lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" |
7796 | 8296 | ;; |
7797 | 8297 | esac |
7798 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5 | |
7799 | $as_echo "$lt_prog_compiler_pic" >&6; } | |
7800 | ||
7801 | ||
7802 | ||
7803 | ||
7804 | ||
8298 | ||
8299 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 | |
8300 | $as_echo_n "checking for $compiler option to produce PIC... " >&6; } | |
8301 | if ${lt_cv_prog_compiler_pic+:} false; then : | |
8302 | $as_echo_n "(cached) " >&6 | |
8303 | else | |
8304 | lt_cv_prog_compiler_pic=$lt_prog_compiler_pic | |
8305 | fi | |
8306 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 | |
8307 | $as_echo "$lt_cv_prog_compiler_pic" >&6; } | |
8308 | lt_prog_compiler_pic=$lt_cv_prog_compiler_pic | |
7805 | 8309 | |
7806 | 8310 | # |
7807 | 8311 | # Check to make sure the PIC flag actually works. |
7856 | 8360 | fi |
7857 | 8361 | |
7858 | 8362 | fi |
8363 | ||
8364 | ||
8365 | ||
8366 | ||
8367 | ||
7859 | 8368 | |
7860 | 8369 | |
7861 | 8370 | |
8212 | 8721 | allow_undefined_flag=unsupported |
8213 | 8722 | always_export_symbols=no |
8214 | 8723 | enable_shared_with_static_runtimes=yes |
8215 | export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' | |
8724 | export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' | |
8725 | exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' | |
8216 | 8726 | |
8217 | 8727 | if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then |
8218 | 8728 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' |
8260 | 8770 | if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ |
8261 | 8771 | && test "$tmp_diet" = no |
8262 | 8772 | then |
8263 | tmp_addflag= | |
8773 | tmp_addflag=' $pic_flag' | |
8264 | 8774 | tmp_sharedflag='-shared' |
8265 | 8775 | case $cc_basename,$host_cpu in |
8266 | 8776 | pgcc*) # Portland Group C compiler |
8330 | 8840 | archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' |
8331 | 8841 | wlarc= |
8332 | 8842 | else |
8333 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
8334 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
8843 | archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
8844 | archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
8335 | 8845 | fi |
8336 | 8846 | ;; |
8337 | 8847 | |
8349 | 8859 | |
8350 | 8860 | _LT_EOF |
8351 | 8861 | elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then |
8352 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
8353 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
8862 | archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
8863 | archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
8354 | 8864 | else |
8355 | 8865 | ld_shlibs=no |
8356 | 8866 | fi |
8396 | 8906 | |
8397 | 8907 | *) |
8398 | 8908 | if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then |
8399 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
8400 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
8909 | archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
8910 | archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
8401 | 8911 | else |
8402 | 8912 | ld_shlibs=no |
8403 | 8913 | fi |
8527 | 9037 | allow_undefined_flag='-berok' |
8528 | 9038 | # Determine the default libpath from the value encoded in an |
8529 | 9039 | # empty executable. |
8530 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9040 | if test "${lt_cv_aix_libpath+set}" = set; then | |
9041 | aix_libpath=$lt_cv_aix_libpath | |
9042 | else | |
9043 | if ${lt_cv_aix_libpath_+:} false; then : | |
9044 | $as_echo_n "(cached) " >&6 | |
9045 | else | |
9046 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8531 | 9047 | /* end confdefs.h. */ |
8532 | 9048 | |
8533 | 9049 | int |
8540 | 9056 | _ACEOF |
8541 | 9057 | if ac_fn_c_try_link "$LINENO"; then : |
8542 | 9058 | |
8543 | lt_aix_libpath_sed=' | |
8544 | /Import File Strings/,/^$/ { | |
8545 | /^0/ { | |
8546 | s/^0 *\(.*\)$/\1/ | |
8547 | p | |
8548 | } | |
8549 | }' | |
8550 | aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
8551 | # Check for a 64-bit object if we didn't find anything. | |
8552 | if test -z "$aix_libpath"; then | |
8553 | aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
8554 | fi | |
9059 | lt_aix_libpath_sed=' | |
9060 | /Import File Strings/,/^$/ { | |
9061 | /^0/ { | |
9062 | s/^0 *\([^ ]*\) *$/\1/ | |
9063 | p | |
9064 | } | |
9065 | }' | |
9066 | lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
9067 | # Check for a 64-bit object if we didn't find anything. | |
9068 | if test -z "$lt_cv_aix_libpath_"; then | |
9069 | lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
9070 | fi | |
8555 | 9071 | fi |
8556 | 9072 | rm -f core conftest.err conftest.$ac_objext \ |
8557 | 9073 | conftest$ac_exeext conftest.$ac_ext |
8558 | if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi | |
9074 | if test -z "$lt_cv_aix_libpath_"; then | |
9075 | lt_cv_aix_libpath_="/usr/lib:/lib" | |
9076 | fi | |
9077 | ||
9078 | fi | |
9079 | ||
9080 | aix_libpath=$lt_cv_aix_libpath_ | |
9081 | fi | |
8559 | 9082 | |
8560 | 9083 | hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" |
8561 | 9084 | archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" |
8567 | 9090 | else |
8568 | 9091 | # Determine the default libpath from the value encoded in an |
8569 | 9092 | # empty executable. |
8570 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9093 | if test "${lt_cv_aix_libpath+set}" = set; then | |
9094 | aix_libpath=$lt_cv_aix_libpath | |
9095 | else | |
9096 | if ${lt_cv_aix_libpath_+:} false; then : | |
9097 | $as_echo_n "(cached) " >&6 | |
9098 | else | |
9099 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8571 | 9100 | /* end confdefs.h. */ |
8572 | 9101 | |
8573 | 9102 | int |
8580 | 9109 | _ACEOF |
8581 | 9110 | if ac_fn_c_try_link "$LINENO"; then : |
8582 | 9111 | |
8583 | lt_aix_libpath_sed=' | |
8584 | /Import File Strings/,/^$/ { | |
8585 | /^0/ { | |
8586 | s/^0 *\(.*\)$/\1/ | |
8587 | p | |
8588 | } | |
8589 | }' | |
8590 | aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
8591 | # Check for a 64-bit object if we didn't find anything. | |
8592 | if test -z "$aix_libpath"; then | |
8593 | aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
8594 | fi | |
9112 | lt_aix_libpath_sed=' | |
9113 | /Import File Strings/,/^$/ { | |
9114 | /^0/ { | |
9115 | s/^0 *\([^ ]*\) *$/\1/ | |
9116 | p | |
9117 | } | |
9118 | }' | |
9119 | lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
9120 | # Check for a 64-bit object if we didn't find anything. | |
9121 | if test -z "$lt_cv_aix_libpath_"; then | |
9122 | lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
9123 | fi | |
8595 | 9124 | fi |
8596 | 9125 | rm -f core conftest.err conftest.$ac_objext \ |
8597 | 9126 | conftest$ac_exeext conftest.$ac_ext |
8598 | if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi | |
9127 | if test -z "$lt_cv_aix_libpath_"; then | |
9128 | lt_cv_aix_libpath_="/usr/lib:/lib" | |
9129 | fi | |
9130 | ||
9131 | fi | |
9132 | ||
9133 | aix_libpath=$lt_cv_aix_libpath_ | |
9134 | fi | |
8599 | 9135 | |
8600 | 9136 | hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" |
8601 | 9137 | # Warning - without using the other run time loading flags, |
8640 | 9176 | # Microsoft Visual C++. |
8641 | 9177 | # hardcode_libdir_flag_spec is actually meaningless, as there is |
8642 | 9178 | # no search path for DLLs. |
8643 | hardcode_libdir_flag_spec=' ' | |
8644 | allow_undefined_flag=unsupported | |
8645 | # Tell ltmain to make .lib files, not .a files. | |
8646 | libext=lib | |
8647 | # Tell ltmain to make .dll files, not .so files. | |
8648 | shrext_cmds=".dll" | |
8649 | # FIXME: Setting linknames here is a bad hack. | |
8650 | archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' | |
8651 | # The linker will automatically build a .lib file if we build a DLL. | |
8652 | old_archive_from_new_cmds='true' | |
8653 | # FIXME: Should let the user specify the lib program. | |
8654 | old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' | |
8655 | fix_srcfile_path='`cygpath -w "$srcfile"`' | |
8656 | enable_shared_with_static_runtimes=yes | |
9179 | case $cc_basename in | |
9180 | cl*) | |
9181 | # Native MSVC | |
9182 | hardcode_libdir_flag_spec=' ' | |
9183 | allow_undefined_flag=unsupported | |
9184 | always_export_symbols=yes | |
9185 | file_list_spec='@' | |
9186 | # Tell ltmain to make .lib files, not .a files. | |
9187 | libext=lib | |
9188 | # Tell ltmain to make .dll files, not .so files. | |
9189 | shrext_cmds=".dll" | |
9190 | # FIXME: Setting linknames here is a bad hack. | |
9191 | archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' | |
9192 | archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then | |
9193 | sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; | |
9194 | else | |
9195 | sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; | |
9196 | fi~ | |
9197 | $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ | |
9198 | linknames=' | |
9199 | # The linker will not automatically build a static lib if we build a DLL. | |
9200 | # _LT_TAGVAR(old_archive_from_new_cmds, )='true' | |
9201 | enable_shared_with_static_runtimes=yes | |
9202 | export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' | |
9203 | # Don't use ranlib | |
9204 | old_postinstall_cmds='chmod 644 $oldlib' | |
9205 | postlink_cmds='lt_outputfile="@OUTPUT@"~ | |
9206 | lt_tool_outputfile="@TOOL_OUTPUT@"~ | |
9207 | case $lt_outputfile in | |
9208 | *.exe|*.EXE) ;; | |
9209 | *) | |
9210 | lt_outputfile="$lt_outputfile.exe" | |
9211 | lt_tool_outputfile="$lt_tool_outputfile.exe" | |
9212 | ;; | |
9213 | esac~ | |
9214 | if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then | |
9215 | $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; | |
9216 | $RM "$lt_outputfile.manifest"; | |
9217 | fi' | |
9218 | ;; | |
9219 | *) | |
9220 | # Assume MSVC wrapper | |
9221 | hardcode_libdir_flag_spec=' ' | |
9222 | allow_undefined_flag=unsupported | |
9223 | # Tell ltmain to make .lib files, not .a files. | |
9224 | libext=lib | |
9225 | # Tell ltmain to make .dll files, not .so files. | |
9226 | shrext_cmds=".dll" | |
9227 | # FIXME: Setting linknames here is a bad hack. | |
9228 | archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' | |
9229 | # The linker will automatically build a .lib file if we build a DLL. | |
9230 | old_archive_from_new_cmds='true' | |
9231 | # FIXME: Should let the user specify the lib program. | |
9232 | old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' | |
9233 | enable_shared_with_static_runtimes=yes | |
9234 | ;; | |
9235 | esac | |
8657 | 9236 | ;; |
8658 | 9237 | |
8659 | 9238 | darwin* | rhapsody*) |
8718 | 9297 | |
8719 | 9298 | # FreeBSD 3 and greater uses gcc -shared to do shared libraries. |
8720 | 9299 | freebsd* | dragonfly*) |
8721 | archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' | |
9300 | archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' | |
8722 | 9301 | hardcode_libdir_flag_spec='-R$libdir' |
8723 | 9302 | hardcode_direct=yes |
8724 | 9303 | hardcode_shlibpath_var=no |
8726 | 9305 | |
8727 | 9306 | hpux9*) |
8728 | 9307 | if test "$GCC" = yes; then |
8729 | archive_cmds='$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' | |
9308 | archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' | |
8730 | 9309 | else |
8731 | 9310 | archive_cmds='$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' |
8732 | 9311 | fi |
8742 | 9321 | |
8743 | 9322 | hpux10*) |
8744 | 9323 | if test "$GCC" = yes && test "$with_gnu_ld" = no; then |
8745 | archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' | |
9324 | archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' | |
8746 | 9325 | else |
8747 | 9326 | archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' |
8748 | 9327 | fi |
8766 | 9345 | archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' |
8767 | 9346 | ;; |
8768 | 9347 | ia64*) |
8769 | archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' | |
9348 | archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' | |
8770 | 9349 | ;; |
8771 | 9350 | *) |
8772 | archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' | |
9351 | archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' | |
8773 | 9352 | ;; |
8774 | 9353 | esac |
8775 | 9354 | else |
8848 | 9427 | |
8849 | 9428 | irix5* | irix6* | nonstopux*) |
8850 | 9429 | if test "$GCC" = yes; then |
8851 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
9430 | archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
8852 | 9431 | # Try to use the -exported_symbol ld option, if it does not |
8853 | 9432 | # work, assume that -exports_file does not work either and |
8854 | 9433 | # implicitly export all symbols. |
8855 | save_LDFLAGS="$LDFLAGS" | |
8856 | LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" | |
8857 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9434 | # This should be the same for all languages, so no per-tag cache variable. | |
9435 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 | |
9436 | $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } | |
9437 | if ${lt_cv_irix_exported_symbol+:} false; then : | |
9438 | $as_echo_n "(cached) " >&6 | |
9439 | else | |
9440 | save_LDFLAGS="$LDFLAGS" | |
9441 | LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" | |
9442 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8858 | 9443 | /* end confdefs.h. */ |
8859 | int foo(void) {} | |
9444 | int foo (void) { return 0; } | |
8860 | 9445 | _ACEOF |
8861 | 9446 | if ac_fn_c_try_link "$LINENO"; then : |
8862 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' | |
8863 | ||
9447 | lt_cv_irix_exported_symbol=yes | |
9448 | else | |
9449 | lt_cv_irix_exported_symbol=no | |
8864 | 9450 | fi |
8865 | 9451 | rm -f core conftest.err conftest.$ac_objext \ |
8866 | 9452 | conftest$ac_exeext conftest.$ac_ext |
8867 | LDFLAGS="$save_LDFLAGS" | |
9453 | LDFLAGS="$save_LDFLAGS" | |
9454 | fi | |
9455 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 | |
9456 | $as_echo "$lt_cv_irix_exported_symbol" >&6; } | |
9457 | if test "$lt_cv_irix_exported_symbol" = yes; then | |
9458 | archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' | |
9459 | fi | |
8868 | 9460 | else |
8869 | 9461 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' |
8870 | 9462 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' |
8949 | 9541 | osf4* | osf5*) # as osf3* with the addition of -msym flag |
8950 | 9542 | if test "$GCC" = yes; then |
8951 | 9543 | allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' |
8952 | archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
9544 | archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
8953 | 9545 | hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' |
8954 | 9546 | else |
8955 | 9547 | allow_undefined_flag=' -expect_unresolved \*' |
8968 | 9560 | no_undefined_flag=' -z defs' |
8969 | 9561 | if test "$GCC" = yes; then |
8970 | 9562 | wlarc='${wl}' |
8971 | archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' | |
9563 | archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' | |
8972 | 9564 | archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ |
8973 | $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' | |
9565 | $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' | |
8974 | 9566 | else |
8975 | 9567 | case `$CC -V 2>&1` in |
8976 | 9568 | *"Compilers 5.0"*) |
9546 | 10138 | need_version=no |
9547 | 10139 | need_lib_prefix=no |
9548 | 10140 | |
9549 | case $GCC,$host_os in | |
9550 | yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) | |
10141 | case $GCC,$cc_basename in | |
10142 | yes,*) | |
10143 | # gcc | |
9551 | 10144 | library_names_spec='$libname.dll.a' |
9552 | 10145 | # DLL is installed to $(libdir)/../bin by postinstall_cmds |
9553 | 10146 | postinstall_cmds='base_file=`basename \${file}`~ |
9580 | 10173 | library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' |
9581 | 10174 | ;; |
9582 | 10175 | esac |
10176 | dynamic_linker='Win32 ld.exe' | |
9583 | 10177 | ;; |
9584 | 10178 | |
10179 | *,cl*) | |
10180 | # Native MSVC | |
10181 | libname_spec='$name' | |
10182 | soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' | |
10183 | library_names_spec='${libname}.dll.lib' | |
10184 | ||
10185 | case $build_os in | |
10186 | mingw*) | |
10187 | sys_lib_search_path_spec= | |
10188 | lt_save_ifs=$IFS | |
10189 | IFS=';' | |
10190 | for lt_path in $LIB | |
10191 | do | |
10192 | IFS=$lt_save_ifs | |
10193 | # Let DOS variable expansion print the short 8.3 style file name. | |
10194 | lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` | |
10195 | sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" | |
10196 | done | |
10197 | IFS=$lt_save_ifs | |
10198 | # Convert to MSYS style. | |
10199 | sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` | |
10200 | ;; | |
10201 | cygwin*) | |
10202 | # Convert to unix form, then to dos form, then back to unix form | |
10203 | # but this time dos style (no spaces!) so that the unix form looks | |
10204 | # like /cygdrive/c/PROGRA~1:/cygdr... | |
10205 | sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` | |
10206 | sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` | |
10207 | sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` | |
10208 | ;; | |
10209 | *) | |
10210 | sys_lib_search_path_spec="$LIB" | |
10211 | if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then | |
10212 | # It is most probably a Windows format PATH. | |
10213 | sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` | |
10214 | else | |
10215 | sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` | |
10216 | fi | |
10217 | # FIXME: find the short name or the path components, as spaces are | |
10218 | # common. (e.g. "Program Files" -> "PROGRA~1") | |
10219 | ;; | |
10220 | esac | |
10221 | ||
10222 | # DLL is installed to $(libdir)/../bin by postinstall_cmds | |
10223 | postinstall_cmds='base_file=`basename \${file}`~ | |
10224 | dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ | |
10225 | dldir=$destdir/`dirname \$dlpath`~ | |
10226 | test -d \$dldir || mkdir -p \$dldir~ | |
10227 | $install_prog $dir/$dlname \$dldir/$dlname' | |
10228 | postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ | |
10229 | dlpath=$dir/\$dldll~ | |
10230 | $RM \$dlpath' | |
10231 | shlibpath_overrides_runpath=yes | |
10232 | dynamic_linker='Win32 link.exe' | |
10233 | ;; | |
10234 | ||
9585 | 10235 | *) |
10236 | # Assume MSVC wrapper | |
9586 | 10237 | library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' |
10238 | dynamic_linker='Win32 ld.exe' | |
9587 | 10239 | ;; |
9588 | 10240 | esac |
9589 | dynamic_linker='Win32 ld.exe' | |
9590 | 10241 | # FIXME: first we should search . and the directory the executable is in |
9591 | 10242 | shlibpath_var=PATH |
9592 | 10243 | ;; |
10526 | 11177 | /* When -fvisbility=hidden is used, assume the code has been annotated |
10527 | 11178 | correspondingly for the symbols needed. */ |
10528 | 11179 | #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) |
10529 | void fnord () __attribute__((visibility("default"))); | |
11180 | int fnord () __attribute__((visibility("default"))); | |
10530 | 11181 | #endif |
10531 | 11182 | |
10532 | void fnord () { int i=42; } | |
11183 | int fnord () { return 42; } | |
10533 | 11184 | int main () |
10534 | 11185 | { |
10535 | 11186 | void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); |
10632 | 11283 | /* When -fvisbility=hidden is used, assume the code has been annotated |
10633 | 11284 | correspondingly for the symbols needed. */ |
10634 | 11285 | #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) |
10635 | void fnord () __attribute__((visibility("default"))); | |
11286 | int fnord () __attribute__((visibility("default"))); | |
10636 | 11287 | #endif |
10637 | 11288 | |
10638 | void fnord () { int i=42; } | |
11289 | int fnord () { return 42; } | |
10639 | 11290 | int main () |
10640 | 11291 | { |
10641 | 11292 | void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); |
11212 | 11863 | fi |
11213 | 11864 | |
11214 | 11865 | |
11866 | ||
11867 | ||
11868 | func_stripname_cnf () | |
11869 | { | |
11870 | case ${2} in | |
11871 | .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; | |
11872 | *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; | |
11873 | esac | |
11874 | } # func_stripname_cnf | |
11875 | ||
11215 | 11876 | if test -n "$CXX" && ( test "X$CXX" != "Xno" && |
11216 | 11877 | ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || |
11217 | 11878 | (test "X$CXX" != "Xg++"))) ; then |
11434 | 12095 | |
11435 | 12096 | # Allow CC to be a program name with arguments. |
11436 | 12097 | lt_save_CC=$CC |
12098 | lt_save_CFLAGS=$CFLAGS | |
11437 | 12099 | lt_save_LD=$LD |
11438 | 12100 | lt_save_GCC=$GCC |
11439 | 12101 | GCC=$GXX |
11451 | 12113 | fi |
11452 | 12114 | test -z "${LDCXX+set}" || LD=$LDCXX |
11453 | 12115 | CC=${CXX-"c++"} |
12116 | CFLAGS=$CXXFLAGS | |
11454 | 12117 | compiler=$CC |
11455 | 12118 | compiler_CXX=$CC |
11456 | 12119 | for cc_temp in $compiler""; do |
11590 | 12253 | # Check if GNU C++ uses GNU ld as the underlying linker, since the |
11591 | 12254 | # archiving commands below assume that GNU ld is being used. |
11592 | 12255 | if test "$with_gnu_ld" = yes; then |
11593 | archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
11594 | archive_expsym_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
12256 | archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
12257 | archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
11595 | 12258 | |
11596 | 12259 | hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' |
11597 | 12260 | export_dynamic_flag_spec_CXX='${wl}--export-dynamic' |
11733 | 12396 | allow_undefined_flag_CXX='-berok' |
11734 | 12397 | # Determine the default libpath from the value encoded in an empty |
11735 | 12398 | # executable. |
11736 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12399 | if test "${lt_cv_aix_libpath+set}" = set; then | |
12400 | aix_libpath=$lt_cv_aix_libpath | |
12401 | else | |
12402 | if ${lt_cv_aix_libpath__CXX+:} false; then : | |
12403 | $as_echo_n "(cached) " >&6 | |
12404 | else | |
12405 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11737 | 12406 | /* end confdefs.h. */ |
11738 | 12407 | |
11739 | 12408 | int |
11746 | 12415 | _ACEOF |
11747 | 12416 | if ac_fn_cxx_try_link "$LINENO"; then : |
11748 | 12417 | |
11749 | lt_aix_libpath_sed=' | |
11750 | /Import File Strings/,/^$/ { | |
11751 | /^0/ { | |
11752 | s/^0 *\(.*\)$/\1/ | |
11753 | p | |
11754 | } | |
11755 | }' | |
11756 | aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
11757 | # Check for a 64-bit object if we didn't find anything. | |
11758 | if test -z "$aix_libpath"; then | |
11759 | aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
11760 | fi | |
12418 | lt_aix_libpath_sed=' | |
12419 | /Import File Strings/,/^$/ { | |
12420 | /^0/ { | |
12421 | s/^0 *\([^ ]*\) *$/\1/ | |
12422 | p | |
12423 | } | |
12424 | }' | |
12425 | lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
12426 | # Check for a 64-bit object if we didn't find anything. | |
12427 | if test -z "$lt_cv_aix_libpath__CXX"; then | |
12428 | lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
12429 | fi | |
11761 | 12430 | fi |
11762 | 12431 | rm -f core conftest.err conftest.$ac_objext \ |
11763 | 12432 | conftest$ac_exeext conftest.$ac_ext |
11764 | if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi | |
12433 | if test -z "$lt_cv_aix_libpath__CXX"; then | |
12434 | lt_cv_aix_libpath__CXX="/usr/lib:/lib" | |
12435 | fi | |
12436 | ||
12437 | fi | |
12438 | ||
12439 | aix_libpath=$lt_cv_aix_libpath__CXX | |
12440 | fi | |
11765 | 12441 | |
11766 | 12442 | hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" |
11767 | 12443 | |
11774 | 12450 | else |
11775 | 12451 | # Determine the default libpath from the value encoded in an |
11776 | 12452 | # empty executable. |
11777 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12453 | if test "${lt_cv_aix_libpath+set}" = set; then | |
12454 | aix_libpath=$lt_cv_aix_libpath | |
12455 | else | |
12456 | if ${lt_cv_aix_libpath__CXX+:} false; then : | |
12457 | $as_echo_n "(cached) " >&6 | |
12458 | else | |
12459 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11778 | 12460 | /* end confdefs.h. */ |
11779 | 12461 | |
11780 | 12462 | int |
11787 | 12469 | _ACEOF |
11788 | 12470 | if ac_fn_cxx_try_link "$LINENO"; then : |
11789 | 12471 | |
11790 | lt_aix_libpath_sed=' | |
11791 | /Import File Strings/,/^$/ { | |
11792 | /^0/ { | |
11793 | s/^0 *\(.*\)$/\1/ | |
11794 | p | |
11795 | } | |
11796 | }' | |
11797 | aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
11798 | # Check for a 64-bit object if we didn't find anything. | |
11799 | if test -z "$aix_libpath"; then | |
11800 | aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
11801 | fi | |
12472 | lt_aix_libpath_sed=' | |
12473 | /Import File Strings/,/^$/ { | |
12474 | /^0/ { | |
12475 | s/^0 *\([^ ]*\) *$/\1/ | |
12476 | p | |
12477 | } | |
12478 | }' | |
12479 | lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
12480 | # Check for a 64-bit object if we didn't find anything. | |
12481 | if test -z "$lt_cv_aix_libpath__CXX"; then | |
12482 | lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
12483 | fi | |
11802 | 12484 | fi |
11803 | 12485 | rm -f core conftest.err conftest.$ac_objext \ |
11804 | 12486 | conftest$ac_exeext conftest.$ac_ext |
11805 | if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi | |
12487 | if test -z "$lt_cv_aix_libpath__CXX"; then | |
12488 | lt_cv_aix_libpath__CXX="/usr/lib:/lib" | |
12489 | fi | |
12490 | ||
12491 | fi | |
12492 | ||
12493 | aix_libpath=$lt_cv_aix_libpath__CXX | |
12494 | fi | |
11806 | 12495 | |
11807 | 12496 | hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" |
11808 | 12497 | # Warning - without using the other run time loading flags, |
11845 | 12534 | ;; |
11846 | 12535 | |
11847 | 12536 | cygwin* | mingw* | pw32* | cegcc*) |
11848 | # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, | |
11849 | # as there is no search path for DLLs. | |
11850 | hardcode_libdir_flag_spec_CXX='-L$libdir' | |
11851 | export_dynamic_flag_spec_CXX='${wl}--export-all-symbols' | |
11852 | allow_undefined_flag_CXX=unsupported | |
11853 | always_export_symbols_CXX=no | |
11854 | enable_shared_with_static_runtimes_CXX=yes | |
11855 | ||
11856 | if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then | |
11857 | archive_cmds_CXX='$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' | |
11858 | # If the export-symbols file already is a .def file (1st line | |
11859 | # is EXPORTS), use it as is; otherwise, prepend... | |
11860 | archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then | |
11861 | cp $export_symbols $output_objdir/$soname.def; | |
11862 | else | |
11863 | echo EXPORTS > $output_objdir/$soname.def; | |
11864 | cat $export_symbols >> $output_objdir/$soname.def; | |
11865 | fi~ | |
11866 | $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' | |
11867 | else | |
11868 | ld_shlibs_CXX=no | |
11869 | fi | |
11870 | ;; | |
12537 | case $GXX,$cc_basename in | |
12538 | ,cl* | no,cl*) | |
12539 | # Native MSVC | |
12540 | # hardcode_libdir_flag_spec is actually meaningless, as there is | |
12541 | # no search path for DLLs. | |
12542 | hardcode_libdir_flag_spec_CXX=' ' | |
12543 | allow_undefined_flag_CXX=unsupported | |
12544 | always_export_symbols_CXX=yes | |
12545 | file_list_spec_CXX='@' | |
12546 | # Tell ltmain to make .lib files, not .a files. | |
12547 | libext=lib | |
12548 | # Tell ltmain to make .dll files, not .so files. | |
12549 | shrext_cmds=".dll" | |
12550 | # FIXME: Setting linknames here is a bad hack. | |
12551 | archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' | |
12552 | archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then | |
12553 | $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; | |
12554 | else | |
12555 | $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; | |
12556 | fi~ | |
12557 | $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ | |
12558 | linknames=' | |
12559 | # The linker will not automatically build a static lib if we build a DLL. | |
12560 | # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true' | |
12561 | enable_shared_with_static_runtimes_CXX=yes | |
12562 | # Don't use ranlib | |
12563 | old_postinstall_cmds_CXX='chmod 644 $oldlib' | |
12564 | postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~ | |
12565 | lt_tool_outputfile="@TOOL_OUTPUT@"~ | |
12566 | case $lt_outputfile in | |
12567 | *.exe|*.EXE) ;; | |
12568 | *) | |
12569 | lt_outputfile="$lt_outputfile.exe" | |
12570 | lt_tool_outputfile="$lt_tool_outputfile.exe" | |
12571 | ;; | |
12572 | esac~ | |
12573 | func_to_tool_file "$lt_outputfile"~ | |
12574 | if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then | |
12575 | $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; | |
12576 | $RM "$lt_outputfile.manifest"; | |
12577 | fi' | |
12578 | ;; | |
12579 | *) | |
12580 | # g++ | |
12581 | # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, | |
12582 | # as there is no search path for DLLs. | |
12583 | hardcode_libdir_flag_spec_CXX='-L$libdir' | |
12584 | export_dynamic_flag_spec_CXX='${wl}--export-all-symbols' | |
12585 | allow_undefined_flag_CXX=unsupported | |
12586 | always_export_symbols_CXX=no | |
12587 | enable_shared_with_static_runtimes_CXX=yes | |
12588 | ||
12589 | if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then | |
12590 | archive_cmds_CXX='$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' | |
12591 | # If the export-symbols file already is a .def file (1st line | |
12592 | # is EXPORTS), use it as is; otherwise, prepend... | |
12593 | archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then | |
12594 | cp $export_symbols $output_objdir/$soname.def; | |
12595 | else | |
12596 | echo EXPORTS > $output_objdir/$soname.def; | |
12597 | cat $export_symbols >> $output_objdir/$soname.def; | |
12598 | fi~ | |
12599 | $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' | |
12600 | else | |
12601 | ld_shlibs_CXX=no | |
12602 | fi | |
12603 | ;; | |
12604 | esac | |
12605 | ;; | |
11871 | 12606 | darwin* | rhapsody*) |
11872 | 12607 | |
11873 | 12608 | |
11973 | 12708 | ;; |
11974 | 12709 | *) |
11975 | 12710 | if test "$GXX" = yes; then |
11976 | archive_cmds_CXX='$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' | |
12711 | archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' | |
11977 | 12712 | else |
11978 | 12713 | # FIXME: insert proper C++ library support |
11979 | 12714 | ld_shlibs_CXX=no |
12044 | 12779 | archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' |
12045 | 12780 | ;; |
12046 | 12781 | ia64*) |
12047 | archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
12782 | archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
12048 | 12783 | ;; |
12049 | 12784 | *) |
12050 | archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
12785 | archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
12051 | 12786 | ;; |
12052 | 12787 | esac |
12053 | 12788 | fi |
12088 | 12823 | *) |
12089 | 12824 | if test "$GXX" = yes; then |
12090 | 12825 | if test "$with_gnu_ld" = no; then |
12091 | archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
12826 | archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
12092 | 12827 | else |
12093 | archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' | |
12828 | archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' | |
12094 | 12829 | fi |
12095 | 12830 | fi |
12096 | 12831 | link_all_deplibs_CXX=yes |
12368 | 13103 | archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' |
12369 | 13104 | ;; |
12370 | 13105 | *) |
12371 | archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
13106 | archive_cmds_CXX='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
12372 | 13107 | ;; |
12373 | 13108 | esac |
12374 | 13109 | |
12455 | 13190 | if test "$GXX" = yes && test "$with_gnu_ld" = no; then |
12456 | 13191 | no_undefined_flag_CXX=' ${wl}-z ${wl}defs' |
12457 | 13192 | if $CC --version | $GREP -v '^2\.7' > /dev/null; then |
12458 | archive_cmds_CXX='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' | |
13193 | archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' | |
12459 | 13194 | archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ |
12460 | $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' | |
13195 | $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' | |
12461 | 13196 | |
12462 | 13197 | # Commands to make compiler produce verbose output that lists |
12463 | 13198 | # what "hidden" libraries, object files and flags are used when |
12592 | 13327 | }; |
12593 | 13328 | _LT_EOF |
12594 | 13329 | |
13330 | ||
13331 | _lt_libdeps_save_CFLAGS=$CFLAGS | |
13332 | case "$CC $CFLAGS " in #( | |
13333 | *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; | |
13334 | *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; | |
13335 | esac | |
13336 | ||
12595 | 13337 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 |
12596 | 13338 | (eval $ac_compile) 2>&5 |
12597 | 13339 | ac_status=$? |
12605 | 13347 | pre_test_object_deps_done=no |
12606 | 13348 | |
12607 | 13349 | for p in `eval "$output_verbose_link_cmd"`; do |
12608 | case $p in | |
13350 | case ${prev}${p} in | |
12609 | 13351 | |
12610 | 13352 | -L* | -R* | -l*) |
12611 | 13353 | # Some compilers place space between "-{L,R}" and the path. |
12614 | 13356 | test $p = "-R"; then |
12615 | 13357 | prev=$p |
12616 | 13358 | continue |
12617 | else | |
12618 | prev= | |
12619 | 13359 | fi |
12620 | 13360 | |
13361 | # Expand the sysroot to ease extracting the directories later. | |
13362 | if test -z "$prev"; then | |
13363 | case $p in | |
13364 | -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; | |
13365 | -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; | |
13366 | -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; | |
13367 | esac | |
13368 | fi | |
13369 | case $p in | |
13370 | =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; | |
13371 | esac | |
12621 | 13372 | if test "$pre_test_object_deps_done" = no; then |
12622 | case $p in | |
12623 | -L* | -R*) | |
13373 | case ${prev} in | |
13374 | -L | -R) | |
12624 | 13375 | # Internal compiler library paths should come after those |
12625 | 13376 | # provided the user. The postdeps already come after the |
12626 | 13377 | # user supplied libs so there is no need to process them. |
12640 | 13391 | postdeps_CXX="${postdeps_CXX} ${prev}${p}" |
12641 | 13392 | fi |
12642 | 13393 | fi |
13394 | prev= | |
12643 | 13395 | ;; |
12644 | 13396 | |
13397 | *.lto.$objext) ;; # Ignore GCC LTO objects | |
12645 | 13398 | *.$objext) |
12646 | 13399 | # This assumes that the test object file only shows up |
12647 | 13400 | # once in the compiler output. |
12677 | 13430 | fi |
12678 | 13431 | |
12679 | 13432 | $RM -f confest.$objext |
13433 | CFLAGS=$_lt_libdeps_save_CFLAGS | |
12680 | 13434 | |
12681 | 13435 | # PORTME: override above test on systems where it is broken |
12682 | 13436 | case $host_os in |
12777 | 13531 | lt_prog_compiler_pic_CXX= |
12778 | 13532 | lt_prog_compiler_static_CXX= |
12779 | 13533 | |
12780 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 | |
12781 | $as_echo_n "checking for $compiler option to produce PIC... " >&6; } | |
12782 | 13534 | |
12783 | 13535 | # C++ specific cases for pic, static, wl, etc. |
12784 | 13536 | if test "$GXX" = yes; then |
12881 | 13633 | # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--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" |
12882 | 13634 | ;; |
12883 | 13635 | esac |
13636 | ;; | |
13637 | mingw* | cygwin* | os2* | pw32* | cegcc*) | |
13638 | # This hack is so that the source file can tell whether it is being | |
13639 | # built for inclusion in a dll (and should export symbols for example). | |
13640 | lt_prog_compiler_pic_CXX='-DDLL_EXPORT' | |
12884 | 13641 | ;; |
12885 | 13642 | dgux*) |
12886 | 13643 | case $cc_basename in |
13099 | 13856 | lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" |
13100 | 13857 | ;; |
13101 | 13858 | esac |
13102 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_CXX" >&5 | |
13103 | $as_echo "$lt_prog_compiler_pic_CXX" >&6; } | |
13104 | ||
13105 | ||
13859 | ||
13860 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 | |
13861 | $as_echo_n "checking for $compiler option to produce PIC... " >&6; } | |
13862 | if ${lt_cv_prog_compiler_pic_CXX+:} false; then : | |
13863 | $as_echo_n "(cached) " >&6 | |
13864 | else | |
13865 | lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX | |
13866 | fi | |
13867 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5 | |
13868 | $as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; } | |
13869 | lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX | |
13106 | 13870 | |
13107 | 13871 | # |
13108 | 13872 | # Check to make sure the PIC flag actually works. |
13157 | 13921 | fi |
13158 | 13922 | |
13159 | 13923 | fi |
13924 | ||
13925 | ||
13160 | 13926 | |
13161 | 13927 | |
13162 | 13928 | |
13337 | 14103 | $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } |
13338 | 14104 | |
13339 | 14105 | export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' |
14106 | exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' | |
13340 | 14107 | case $host_os in |
13341 | 14108 | aix[4-9]*) |
13342 | 14109 | # If we're using GNU nm, then we don't want the "-C" option. |
13351 | 14118 | ;; |
13352 | 14119 | pw32*) |
13353 | 14120 | export_symbols_cmds_CXX="$ltdll_cmds" |
13354 | ;; | |
14121 | ;; | |
13355 | 14122 | cygwin* | mingw* | cegcc*) |
13356 | export_symbols_cmds_CXX='$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' | |
13357 | ;; | |
14123 | case $cc_basename in | |
14124 | cl*) ;; | |
14125 | *) | |
14126 | export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' | |
14127 | exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' | |
14128 | ;; | |
14129 | esac | |
14130 | ;; | |
13358 | 14131 | *) |
13359 | 14132 | export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' |
13360 | ;; | |
14133 | ;; | |
13361 | 14134 | esac |
13362 | exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' | |
13363 | 14135 | |
13364 | 14136 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 |
13365 | 14137 | $as_echo "$ld_shlibs_CXX" >&6; } |
13622 | 14394 | need_version=no |
13623 | 14395 | need_lib_prefix=no |
13624 | 14396 | |
13625 | case $GCC,$host_os in | |
13626 | yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) | |
14397 | case $GCC,$cc_basename in | |
14398 | yes,*) | |
14399 | # gcc | |
13627 | 14400 | library_names_spec='$libname.dll.a' |
13628 | 14401 | # DLL is installed to $(libdir)/../bin by postinstall_cmds |
13629 | 14402 | postinstall_cmds='base_file=`basename \${file}`~ |
13655 | 14428 | library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' |
13656 | 14429 | ;; |
13657 | 14430 | esac |
14431 | dynamic_linker='Win32 ld.exe' | |
13658 | 14432 | ;; |
13659 | 14433 | |
14434 | *,cl*) | |
14435 | # Native MSVC | |
14436 | libname_spec='$name' | |
14437 | soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' | |
14438 | library_names_spec='${libname}.dll.lib' | |
14439 | ||
14440 | case $build_os in | |
14441 | mingw*) | |
14442 | sys_lib_search_path_spec= | |
14443 | lt_save_ifs=$IFS | |
14444 | IFS=';' | |
14445 | for lt_path in $LIB | |
14446 | do | |
14447 | IFS=$lt_save_ifs | |
14448 | # Let DOS variable expansion print the short 8.3 style file name. | |
14449 | lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` | |
14450 | sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" | |
14451 | done | |
14452 | IFS=$lt_save_ifs | |
14453 | # Convert to MSYS style. | |
14454 | sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` | |
14455 | ;; | |
14456 | cygwin*) | |
14457 | # Convert to unix form, then to dos form, then back to unix form | |
14458 | # but this time dos style (no spaces!) so that the unix form looks | |
14459 | # like /cygdrive/c/PROGRA~1:/cygdr... | |
14460 | sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` | |
14461 | sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` | |
14462 | sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` | |
14463 | ;; | |
14464 | *) | |
14465 | sys_lib_search_path_spec="$LIB" | |
14466 | if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then | |
14467 | # It is most probably a Windows format PATH. | |
14468 | sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` | |
14469 | else | |
14470 | sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` | |
14471 | fi | |
14472 | # FIXME: find the short name or the path components, as spaces are | |
14473 | # common. (e.g. "Program Files" -> "PROGRA~1") | |
14474 | ;; | |
14475 | esac | |
14476 | ||
14477 | # DLL is installed to $(libdir)/../bin by postinstall_cmds | |
14478 | postinstall_cmds='base_file=`basename \${file}`~ | |
14479 | dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ | |
14480 | dldir=$destdir/`dirname \$dlpath`~ | |
14481 | test -d \$dldir || mkdir -p \$dldir~ | |
14482 | $install_prog $dir/$dlname \$dldir/$dlname' | |
14483 | postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ | |
14484 | dlpath=$dir/\$dldll~ | |
14485 | $RM \$dlpath' | |
14486 | shlibpath_overrides_runpath=yes | |
14487 | dynamic_linker='Win32 link.exe' | |
14488 | ;; | |
14489 | ||
13660 | 14490 | *) |
14491 | # Assume MSVC wrapper | |
13661 | 14492 | library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' |
14493 | dynamic_linker='Win32 ld.exe' | |
13662 | 14494 | ;; |
13663 | 14495 | esac |
13664 | dynamic_linker='Win32 ld.exe' | |
13665 | 14496 | # FIXME: first we should search . and the directory the executable is in |
13666 | 14497 | shlibpath_var=PATH |
13667 | 14498 | ;; |
14219 | 15050 | fi # test -n "$compiler" |
14220 | 15051 | |
14221 | 15052 | CC=$lt_save_CC |
15053 | CFLAGS=$lt_save_CFLAGS | |
14222 | 15054 | LDCXX=$LD |
14223 | 15055 | LD=$lt_save_LD |
14224 | 15056 | GCC=$lt_save_GCC |
15364 | 16196 | lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' |
15365 | 16197 | lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' |
15366 | 16198 | lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' |
16199 | lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' | |
16200 | lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' | |
15367 | 16201 | reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' |
15368 | 16202 | reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' |
15369 | 16203 | OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' |
15370 | 16204 | deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' |
15371 | 16205 | file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' |
16206 | file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' | |
16207 | want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' | |
16208 | DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' | |
16209 | sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' | |
15372 | 16210 | AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' |
15373 | 16211 | AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' |
16212 | archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' | |
15374 | 16213 | STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' |
15375 | 16214 | RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' |
15376 | 16215 | old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' |
15385 | 16224 | lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' |
15386 | 16225 | lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' |
15387 | 16226 | lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' |
16227 | nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' | |
16228 | lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' | |
15388 | 16229 | objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' |
15389 | 16230 | MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' |
15390 | 16231 | lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' |
16232 | lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' | |
15391 | 16233 | lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' |
15392 | lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' | |
15393 | 16234 | lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' |
15394 | 16235 | lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' |
15395 | 16236 | need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' |
16237 | MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' | |
15396 | 16238 | DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' |
15397 | 16239 | NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' |
15398 | 16240 | LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' |
15425 | 16267 | hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' |
15426 | 16268 | inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' |
15427 | 16269 | link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' |
15428 | fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`' | |
15429 | 16270 | always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' |
15430 | 16271 | export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' |
15431 | 16272 | exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' |
15432 | 16273 | include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' |
15433 | 16274 | prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' |
16275 | postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' | |
15434 | 16276 | file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' |
15435 | 16277 | variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' |
15436 | 16278 | need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' |
15469 | 16311 | compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`' |
15470 | 16312 | GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`' |
15471 | 16313 | lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`' |
16314 | lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`' | |
15472 | 16315 | lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`' |
15473 | lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`' | |
15474 | 16316 | lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`' |
15475 | 16317 | lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`' |
15476 | 16318 | archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`' |
15497 | 16339 | hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`' |
15498 | 16340 | inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`' |
15499 | 16341 | link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`' |
15500 | fix_srcfile_path_CXX='`$ECHO "$fix_srcfile_path_CXX" | $SED "$delay_single_quote_subst"`' | |
15501 | 16342 | always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`' |
15502 | 16343 | export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`' |
15503 | 16344 | exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`' |
15504 | 16345 | include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`' |
15505 | 16346 | prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`' |
16347 | postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`' | |
15506 | 16348 | file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`' |
15507 | 16349 | hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`' |
15508 | 16350 | compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`' |
15540 | 16382 | OBJDUMP \ |
15541 | 16383 | deplibs_check_method \ |
15542 | 16384 | file_magic_cmd \ |
16385 | file_magic_glob \ | |
16386 | want_nocaseglob \ | |
16387 | DLLTOOL \ | |
16388 | sharedlib_from_linklib_cmd \ | |
15543 | 16389 | AR \ |
15544 | 16390 | AR_FLAGS \ |
16391 | archiver_list_spec \ | |
15545 | 16392 | STRIP \ |
15546 | 16393 | RANLIB \ |
15547 | 16394 | CC \ |
15551 | 16398 | lt_cv_sys_global_symbol_to_cdecl \ |
15552 | 16399 | lt_cv_sys_global_symbol_to_c_name_address \ |
15553 | 16400 | lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ |
16401 | nm_file_list_spec \ | |
15554 | 16402 | lt_prog_compiler_no_builtin_flag \ |
16403 | lt_prog_compiler_pic \ | |
15555 | 16404 | lt_prog_compiler_wl \ |
15556 | lt_prog_compiler_pic \ | |
15557 | 16405 | lt_prog_compiler_static \ |
15558 | 16406 | lt_cv_prog_compiler_c_o \ |
15559 | 16407 | need_locks \ |
16408 | MANIFEST_TOOL \ | |
15560 | 16409 | DSYMUTIL \ |
15561 | 16410 | NMEDIT \ |
15562 | 16411 | LIPO \ |
15572 | 16421 | hardcode_libdir_flag_spec \ |
15573 | 16422 | hardcode_libdir_flag_spec_ld \ |
15574 | 16423 | hardcode_libdir_separator \ |
15575 | fix_srcfile_path \ | |
15576 | 16424 | exclude_expsyms \ |
15577 | 16425 | include_expsyms \ |
15578 | 16426 | file_list_spec \ |
15594 | 16442 | reload_flag_CXX \ |
15595 | 16443 | compiler_CXX \ |
15596 | 16444 | lt_prog_compiler_no_builtin_flag_CXX \ |
16445 | lt_prog_compiler_pic_CXX \ | |
15597 | 16446 | lt_prog_compiler_wl_CXX \ |
15598 | lt_prog_compiler_pic_CXX \ | |
15599 | 16447 | lt_prog_compiler_static_CXX \ |
15600 | 16448 | lt_cv_prog_compiler_c_o_CXX \ |
15601 | 16449 | export_dynamic_flag_spec_CXX \ |
15607 | 16455 | hardcode_libdir_flag_spec_CXX \ |
15608 | 16456 | hardcode_libdir_flag_spec_ld_CXX \ |
15609 | 16457 | hardcode_libdir_separator_CXX \ |
15610 | fix_srcfile_path_CXX \ | |
15611 | 16458 | exclude_expsyms_CXX \ |
15612 | 16459 | include_expsyms_CXX \ |
15613 | 16460 | file_list_spec_CXX \ |
15641 | 16488 | module_expsym_cmds \ |
15642 | 16489 | export_symbols_cmds \ |
15643 | 16490 | prelink_cmds \ |
16491 | postlink_cmds \ | |
15644 | 16492 | postinstall_cmds \ |
15645 | 16493 | postuninstall_cmds \ |
15646 | 16494 | finish_cmds \ |
15655 | 16503 | module_cmds_CXX \ |
15656 | 16504 | module_expsym_cmds_CXX \ |
15657 | 16505 | export_symbols_cmds_CXX \ |
15658 | prelink_cmds_CXX; do | |
16506 | prelink_cmds_CXX \ | |
16507 | postlink_cmds_CXX; do | |
15659 | 16508 | case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in |
15660 | 16509 | *[\\\\\\\`\\"\\\$]*) |
15661 | 16510 | eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" |
16353 | 17202 | # turn newlines into spaces. |
16354 | 17203 | NL2SP=$lt_lt_NL2SP |
16355 | 17204 | |
17205 | # convert \$build file names to \$host format. | |
17206 | to_host_file_cmd=$lt_cv_to_host_file_cmd | |
17207 | ||
17208 | # convert \$build files to toolchain format. | |
17209 | to_tool_file_cmd=$lt_cv_to_tool_file_cmd | |
17210 | ||
16356 | 17211 | # An object symbol dumper. |
16357 | 17212 | OBJDUMP=$lt_OBJDUMP |
16358 | 17213 | |
16359 | 17214 | # Method to check whether dependent libraries are shared objects. |
16360 | 17215 | deplibs_check_method=$lt_deplibs_check_method |
16361 | 17216 | |
16362 | # Command to use when deplibs_check_method == "file_magic". | |
17217 | # Command to use when deplibs_check_method = "file_magic". | |
16363 | 17218 | file_magic_cmd=$lt_file_magic_cmd |
17219 | ||
17220 | # How to find potential files when deplibs_check_method = "file_magic". | |
17221 | file_magic_glob=$lt_file_magic_glob | |
17222 | ||
17223 | # Find potential files using nocaseglob when deplibs_check_method = "file_magic". | |
17224 | want_nocaseglob=$lt_want_nocaseglob | |
17225 | ||
17226 | # DLL creation program. | |
17227 | DLLTOOL=$lt_DLLTOOL | |
17228 | ||
17229 | # Command to associate shared and link libraries. | |
17230 | sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd | |
16364 | 17231 | |
16365 | 17232 | # The archiver. |
16366 | 17233 | AR=$lt_AR |
17234 | ||
17235 | # Flags to create an archive. | |
16367 | 17236 | AR_FLAGS=$lt_AR_FLAGS |
17237 | ||
17238 | # How to feed a file listing to the archiver. | |
17239 | archiver_list_spec=$lt_archiver_list_spec | |
16368 | 17240 | |
16369 | 17241 | # A symbol stripping program. |
16370 | 17242 | STRIP=$lt_STRIP |
16395 | 17267 | # Transform the output of nm in a C name address pair when lib prefix is needed. |
16396 | 17268 | global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix |
16397 | 17269 | |
17270 | # Specify filename containing input files for \$NM. | |
17271 | nm_file_list_spec=$lt_nm_file_list_spec | |
17272 | ||
17273 | # The root where to search for dependent libraries,and in which our libraries should be installed. | |
17274 | lt_sysroot=$lt_sysroot | |
17275 | ||
16398 | 17276 | # The name of the directory that contains temporary libtool files. |
16399 | 17277 | objdir=$objdir |
16400 | 17278 | |
16403 | 17281 | |
16404 | 17282 | # Must we lock files when doing compilation? |
16405 | 17283 | need_locks=$lt_need_locks |
17284 | ||
17285 | # Manifest tool. | |
17286 | MANIFEST_TOOL=$lt_MANIFEST_TOOL | |
16406 | 17287 | |
16407 | 17288 | # Tool to manipulate archived DWARF debug symbol files on Mac OS X. |
16408 | 17289 | DSYMUTIL=$lt_DSYMUTIL |
16518 | 17399 | # Compiler flag to turn off builtin functions. |
16519 | 17400 | no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag |
16520 | 17401 | |
17402 | # Additional compiler flags for building library objects. | |
17403 | pic_flag=$lt_lt_prog_compiler_pic | |
17404 | ||
16521 | 17405 | # How to pass a linker flag through the compiler. |
16522 | 17406 | wl=$lt_lt_prog_compiler_wl |
16523 | ||
16524 | # Additional compiler flags for building library objects. | |
16525 | pic_flag=$lt_lt_prog_compiler_pic | |
16526 | 17407 | |
16527 | 17408 | # Compiler flag to prevent dynamic linking. |
16528 | 17409 | link_static_flag=$lt_lt_prog_compiler_static |
16610 | 17491 | # Whether libtool must link a program against all its dependency libraries. |
16611 | 17492 | link_all_deplibs=$link_all_deplibs |
16612 | 17493 | |
16613 | # Fix the shell variable \$srcfile for the compiler. | |
16614 | fix_srcfile_path=$lt_fix_srcfile_path | |
16615 | ||
16616 | 17494 | # Set to "yes" if exported symbols are required. |
16617 | 17495 | always_export_symbols=$always_export_symbols |
16618 | 17496 | |
16627 | 17505 | |
16628 | 17506 | # Commands necessary for linking programs (against libraries) with templates. |
16629 | 17507 | prelink_cmds=$lt_prelink_cmds |
17508 | ||
17509 | # Commands necessary for finishing linking programs. | |
17510 | postlink_cmds=$lt_postlink_cmds | |
16630 | 17511 | |
16631 | 17512 | # Specify filename containing input files. |
16632 | 17513 | file_list_spec=$lt_file_list_spec |
16674 | 17555 | # if finds mixed CR/LF and LF-only lines. Since sed operates in |
16675 | 17556 | # text mode, it properly converts lines to CR/LF. This bash problem |
16676 | 17557 | # is reportedly fixed, but why not run on old versions too? |
16677 | sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \ | |
16678 | || (rm -f "$cfgfile"; exit 1) | |
16679 | ||
16680 | case $xsi_shell in | |
16681 | yes) | |
16682 | cat << \_LT_EOF >> "$cfgfile" | |
16683 | ||
16684 | # func_dirname file append nondir_replacement | |
16685 | # Compute the dirname of FILE. If nonempty, add APPEND to the result, | |
16686 | # otherwise set result to NONDIR_REPLACEMENT. | |
16687 | func_dirname () | |
16688 | { | |
16689 | case ${1} in | |
16690 | */*) func_dirname_result="${1%/*}${2}" ;; | |
16691 | * ) func_dirname_result="${3}" ;; | |
16692 | esac | |
16693 | } | |
16694 | ||
16695 | # func_basename file | |
16696 | func_basename () | |
16697 | { | |
16698 | func_basename_result="${1##*/}" | |
16699 | } | |
16700 | ||
16701 | # func_dirname_and_basename file append nondir_replacement | |
16702 | # perform func_basename and func_dirname in a single function | |
16703 | # call: | |
16704 | # dirname: Compute the dirname of FILE. If nonempty, | |
16705 | # add APPEND to the result, otherwise set result | |
16706 | # to NONDIR_REPLACEMENT. | |
16707 | # value returned in "$func_dirname_result" | |
16708 | # basename: Compute filename of FILE. | |
16709 | # value retuned in "$func_basename_result" | |
16710 | # Implementation must be kept synchronized with func_dirname | |
16711 | # and func_basename. For efficiency, we do not delegate to | |
16712 | # those functions but instead duplicate the functionality here. | |
16713 | func_dirname_and_basename () | |
16714 | { | |
16715 | case ${1} in | |
16716 | */*) func_dirname_result="${1%/*}${2}" ;; | |
16717 | * ) func_dirname_result="${3}" ;; | |
16718 | esac | |
16719 | func_basename_result="${1##*/}" | |
16720 | } | |
16721 | ||
16722 | # func_stripname prefix suffix name | |
16723 | # strip PREFIX and SUFFIX off of NAME. | |
16724 | # PREFIX and SUFFIX must not contain globbing or regex special | |
16725 | # characters, hashes, percent signs, but SUFFIX may contain a leading | |
16726 | # dot (in which case that matches only a dot). | |
16727 | func_stripname () | |
16728 | { | |
16729 | # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are | |
16730 | # positional parameters, so assign one to ordinary parameter first. | |
16731 | func_stripname_result=${3} | |
16732 | func_stripname_result=${func_stripname_result#"${1}"} | |
16733 | func_stripname_result=${func_stripname_result%"${2}"} | |
16734 | } | |
16735 | ||
16736 | # func_opt_split | |
16737 | func_opt_split () | |
16738 | { | |
16739 | func_opt_split_opt=${1%%=*} | |
16740 | func_opt_split_arg=${1#*=} | |
16741 | } | |
16742 | ||
16743 | # func_lo2o object | |
16744 | func_lo2o () | |
16745 | { | |
16746 | case ${1} in | |
16747 | *.lo) func_lo2o_result=${1%.lo}.${objext} ;; | |
16748 | *) func_lo2o_result=${1} ;; | |
16749 | esac | |
16750 | } | |
16751 | ||
16752 | # func_xform libobj-or-source | |
16753 | func_xform () | |
16754 | { | |
16755 | func_xform_result=${1%.*}.lo | |
16756 | } | |
16757 | ||
16758 | # func_arith arithmetic-term... | |
16759 | func_arith () | |
16760 | { | |
16761 | func_arith_result=$(( $* )) | |
16762 | } | |
16763 | ||
16764 | # func_len string | |
16765 | # STRING may not start with a hyphen. | |
16766 | func_len () | |
16767 | { | |
16768 | func_len_result=${#1} | |
16769 | } | |
16770 | ||
16771 | _LT_EOF | |
16772 | ;; | |
16773 | *) # Bourne compatible functions. | |
16774 | cat << \_LT_EOF >> "$cfgfile" | |
16775 | ||
16776 | # func_dirname file append nondir_replacement | |
16777 | # Compute the dirname of FILE. If nonempty, add APPEND to the result, | |
16778 | # otherwise set result to NONDIR_REPLACEMENT. | |
16779 | func_dirname () | |
16780 | { | |
16781 | # Extract subdirectory from the argument. | |
16782 | func_dirname_result=`$ECHO "${1}" | $SED "$dirname"` | |
16783 | if test "X$func_dirname_result" = "X${1}"; then | |
16784 | func_dirname_result="${3}" | |
16785 | else | |
16786 | func_dirname_result="$func_dirname_result${2}" | |
16787 | fi | |
16788 | } | |
16789 | ||
16790 | # func_basename file | |
16791 | func_basename () | |
16792 | { | |
16793 | func_basename_result=`$ECHO "${1}" | $SED "$basename"` | |
16794 | } | |
16795 | ||
16796 | ||
16797 | # func_stripname prefix suffix name | |
16798 | # strip PREFIX and SUFFIX off of NAME. | |
16799 | # PREFIX and SUFFIX must not contain globbing or regex special | |
16800 | # characters, hashes, percent signs, but SUFFIX may contain a leading | |
16801 | # dot (in which case that matches only a dot). | |
16802 | # func_strip_suffix prefix name | |
16803 | func_stripname () | |
16804 | { | |
16805 | case ${2} in | |
16806 | .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; | |
16807 | *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; | |
16808 | esac | |
16809 | } | |
16810 | ||
16811 | # sed scripts: | |
16812 | my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q' | |
16813 | my_sed_long_arg='1s/^-[^=]*=//' | |
16814 | ||
16815 | # func_opt_split | |
16816 | func_opt_split () | |
16817 | { | |
16818 | func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"` | |
16819 | func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"` | |
16820 | } | |
16821 | ||
16822 | # func_lo2o object | |
16823 | func_lo2o () | |
16824 | { | |
16825 | func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` | |
16826 | } | |
16827 | ||
16828 | # func_xform libobj-or-source | |
16829 | func_xform () | |
16830 | { | |
16831 | func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'` | |
16832 | } | |
16833 | ||
16834 | # func_arith arithmetic-term... | |
16835 | func_arith () | |
16836 | { | |
16837 | func_arith_result=`expr "$@"` | |
16838 | } | |
16839 | ||
16840 | # func_len string | |
16841 | # STRING may not start with a hyphen. | |
16842 | func_len () | |
16843 | { | |
16844 | func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len` | |
16845 | } | |
16846 | ||
16847 | _LT_EOF | |
16848 | esac | |
16849 | ||
16850 | case $lt_shell_append in | |
16851 | yes) | |
16852 | cat << \_LT_EOF >> "$cfgfile" | |
16853 | ||
16854 | # func_append var value | |
16855 | # Append VALUE to the end of shell variable VAR. | |
16856 | func_append () | |
16857 | { | |
16858 | eval "$1+=\$2" | |
16859 | } | |
16860 | _LT_EOF | |
16861 | ;; | |
16862 | *) | |
16863 | cat << \_LT_EOF >> "$cfgfile" | |
16864 | ||
16865 | # func_append var value | |
16866 | # Append VALUE to the end of shell variable VAR. | |
16867 | func_append () | |
16868 | { | |
16869 | eval "$1=\$$1\$2" | |
16870 | } | |
16871 | ||
16872 | _LT_EOF | |
16873 | ;; | |
16874 | esac | |
16875 | ||
16876 | ||
16877 | sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \ | |
16878 | || (rm -f "$cfgfile"; exit 1) | |
16879 | ||
16880 | mv -f "$cfgfile" "$ofile" || | |
17558 | sed '$q' "$ltmain" >> "$cfgfile" \ | |
17559 | || (rm -f "$cfgfile"; exit 1) | |
17560 | ||
17561 | if test x"$xsi_shell" = xyes; then | |
17562 | sed -e '/^func_dirname ()$/,/^} # func_dirname /c\ | |
17563 | func_dirname ()\ | |
17564 | {\ | |
17565 | \ case ${1} in\ | |
17566 | \ */*) func_dirname_result="${1%/*}${2}" ;;\ | |
17567 | \ * ) func_dirname_result="${3}" ;;\ | |
17568 | \ esac\ | |
17569 | } # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \ | |
17570 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17571 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17572 | test 0 -eq $? || _lt_function_replace_fail=: | |
17573 | ||
17574 | ||
17575 | sed -e '/^func_basename ()$/,/^} # func_basename /c\ | |
17576 | func_basename ()\ | |
17577 | {\ | |
17578 | \ func_basename_result="${1##*/}"\ | |
17579 | } # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \ | |
17580 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17581 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17582 | test 0 -eq $? || _lt_function_replace_fail=: | |
17583 | ||
17584 | ||
17585 | sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\ | |
17586 | func_dirname_and_basename ()\ | |
17587 | {\ | |
17588 | \ case ${1} in\ | |
17589 | \ */*) func_dirname_result="${1%/*}${2}" ;;\ | |
17590 | \ * ) func_dirname_result="${3}" ;;\ | |
17591 | \ esac\ | |
17592 | \ func_basename_result="${1##*/}"\ | |
17593 | } # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \ | |
17594 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17595 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17596 | test 0 -eq $? || _lt_function_replace_fail=: | |
17597 | ||
17598 | ||
17599 | sed -e '/^func_stripname ()$/,/^} # func_stripname /c\ | |
17600 | func_stripname ()\ | |
17601 | {\ | |
17602 | \ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\ | |
17603 | \ # positional parameters, so assign one to ordinary parameter first.\ | |
17604 | \ func_stripname_result=${3}\ | |
17605 | \ func_stripname_result=${func_stripname_result#"${1}"}\ | |
17606 | \ func_stripname_result=${func_stripname_result%"${2}"}\ | |
17607 | } # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \ | |
17608 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17609 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17610 | test 0 -eq $? || _lt_function_replace_fail=: | |
17611 | ||
17612 | ||
17613 | sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\ | |
17614 | func_split_long_opt ()\ | |
17615 | {\ | |
17616 | \ func_split_long_opt_name=${1%%=*}\ | |
17617 | \ func_split_long_opt_arg=${1#*=}\ | |
17618 | } # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \ | |
17619 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17620 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17621 | test 0 -eq $? || _lt_function_replace_fail=: | |
17622 | ||
17623 | ||
17624 | sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\ | |
17625 | func_split_short_opt ()\ | |
17626 | {\ | |
17627 | \ func_split_short_opt_arg=${1#??}\ | |
17628 | \ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\ | |
17629 | } # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \ | |
17630 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17631 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17632 | test 0 -eq $? || _lt_function_replace_fail=: | |
17633 | ||
17634 | ||
17635 | sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\ | |
17636 | func_lo2o ()\ | |
17637 | {\ | |
17638 | \ case ${1} in\ | |
17639 | \ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\ | |
17640 | \ *) func_lo2o_result=${1} ;;\ | |
17641 | \ esac\ | |
17642 | } # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \ | |
17643 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17644 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17645 | test 0 -eq $? || _lt_function_replace_fail=: | |
17646 | ||
17647 | ||
17648 | sed -e '/^func_xform ()$/,/^} # func_xform /c\ | |
17649 | func_xform ()\ | |
17650 | {\ | |
17651 | func_xform_result=${1%.*}.lo\ | |
17652 | } # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \ | |
17653 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17654 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17655 | test 0 -eq $? || _lt_function_replace_fail=: | |
17656 | ||
17657 | ||
17658 | sed -e '/^func_arith ()$/,/^} # func_arith /c\ | |
17659 | func_arith ()\ | |
17660 | {\ | |
17661 | func_arith_result=$(( $* ))\ | |
17662 | } # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \ | |
17663 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17664 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17665 | test 0 -eq $? || _lt_function_replace_fail=: | |
17666 | ||
17667 | ||
17668 | sed -e '/^func_len ()$/,/^} # func_len /c\ | |
17669 | func_len ()\ | |
17670 | {\ | |
17671 | func_len_result=${#1}\ | |
17672 | } # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \ | |
17673 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17674 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17675 | test 0 -eq $? || _lt_function_replace_fail=: | |
17676 | ||
17677 | fi | |
17678 | ||
17679 | if test x"$lt_shell_append" = xyes; then | |
17680 | sed -e '/^func_append ()$/,/^} # func_append /c\ | |
17681 | func_append ()\ | |
17682 | {\ | |
17683 | eval "${1}+=\\${2}"\ | |
17684 | } # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \ | |
17685 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17686 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17687 | test 0 -eq $? || _lt_function_replace_fail=: | |
17688 | ||
17689 | ||
17690 | sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\ | |
17691 | func_append_quoted ()\ | |
17692 | {\ | |
17693 | \ func_quote_for_eval "${2}"\ | |
17694 | \ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\ | |
17695 | } # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \ | |
17696 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17697 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17698 | test 0 -eq $? || _lt_function_replace_fail=: | |
17699 | ||
17700 | ||
17701 | # Save a `func_append' function call where possible by direct use of '+=' | |
17702 | sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ | |
17703 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17704 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17705 | test 0 -eq $? || _lt_function_replace_fail=: | |
17706 | else | |
17707 | # Save a `func_append' function call even when '+=' is not available | |
17708 | sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ | |
17709 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
17710 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
17711 | test 0 -eq $? || _lt_function_replace_fail=: | |
17712 | fi | |
17713 | ||
17714 | if test x"$_lt_function_replace_fail" = x":"; then | |
17715 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5 | |
17716 | $as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;} | |
17717 | fi | |
17718 | ||
17719 | ||
17720 | mv -f "$cfgfile" "$ofile" || | |
16881 | 17721 | (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") |
16882 | 17722 | chmod +x "$ofile" |
16883 | 17723 | |
16905 | 17745 | # Compiler flag to turn off builtin functions. |
16906 | 17746 | no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX |
16907 | 17747 | |
17748 | # Additional compiler flags for building library objects. | |
17749 | pic_flag=$lt_lt_prog_compiler_pic_CXX | |
17750 | ||
16908 | 17751 | # How to pass a linker flag through the compiler. |
16909 | 17752 | wl=$lt_lt_prog_compiler_wl_CXX |
16910 | ||
16911 | # Additional compiler flags for building library objects. | |
16912 | pic_flag=$lt_lt_prog_compiler_pic_CXX | |
16913 | 17753 | |
16914 | 17754 | # Compiler flag to prevent dynamic linking. |
16915 | 17755 | link_static_flag=$lt_lt_prog_compiler_static_CXX |
16997 | 17837 | # Whether libtool must link a program against all its dependency libraries. |
16998 | 17838 | link_all_deplibs=$link_all_deplibs_CXX |
16999 | 17839 | |
17000 | # Fix the shell variable \$srcfile for the compiler. | |
17001 | fix_srcfile_path=$lt_fix_srcfile_path_CXX | |
17002 | ||
17003 | 17840 | # Set to "yes" if exported symbols are required. |
17004 | 17841 | always_export_symbols=$always_export_symbols_CXX |
17005 | 17842 | |
17014 | 17851 | |
17015 | 17852 | # Commands necessary for linking programs (against libraries) with templates. |
17016 | 17853 | prelink_cmds=$lt_prelink_cmds_CXX |
17854 | ||
17855 | # Commands necessary for finishing linking programs. | |
17856 | postlink_cmds=$lt_postlink_cmds_CXX | |
17017 | 17857 | |
17018 | 17858 | # Specify filename containing input files. |
17019 | 17859 | file_list_spec=$lt_file_list_spec_CXX |
0 | # $Id: configure.ac,v 1.19 2012/07/14 05:07:40 sarrazip Exp $ | |
0 | # $Id: configure.ac,v 1.22 2013/02/25 05:04:42 sarrazip Exp $ | |
1 | 1 | # configure.ac for burgerspace |
2 | 2 | |
3 | 3 | AC_PREREQ(2.50) |
4 | 4 | AC_INIT(src/BurgerSpaceClient.h) |
5 | 5 | AC_CANONICAL_HOST |
6 | 6 | AC_CANONICAL_SYSTEM |
7 | AM_INIT_AUTOMAKE(burgerspace, 1.9.1) | |
7 | AM_INIT_AUTOMAKE(burgerspace, 1.9.2) | |
8 | 8 | |
9 | MANUAL_DATE_EN="July 14th, 2012"; AC_SUBST(MANUAL_DATE_EN) | |
10 | MANUAL_DATE_FR="14 juillet 2012"; AC_SUBST(MANUAL_DATE_FR) # UTF-8 | |
9 | MANUAL_DATE_EN="February 25th, 2013"; AC_SUBST(MANUAL_DATE_EN) | |
10 | MANUAL_DATE_FR="25 février 2013"; AC_SUBST(MANUAL_DATE_FR) # UTF-8 | |
11 | 11 | |
12 | 12 | PACKAGE_FULL_NAME="BurgerSpace" |
13 | 13 | PACKAGE_SUMMARY_EN="A hamburger-smashing video game" |
63 | 63 | |
64 | 64 | DEFAULT_UDP_SERVER_PORT=49152 # private as per IANA |
65 | 65 | AC_ARG_WITH([default-udp-port], |
66 | [ --with-default-udp-port default UDP port number on which to accept clients (default: $DEFAULT_UDP_SERVER_PORT)], | |
66 | [ --with-default-udp-port default UDP port number on which to accept clients (default: 49152)], | |
67 | 67 | [ |
68 | 68 | if test "$withval" = no; then |
69 | 69 | true |
0 | .\" $Id: burgerspace-server.6.in,v 1.2 2010/05/26 03:13:01 sarrazip Exp $ | |
0 | .\" $Id: burgerspace-server.6.in,v 1.3 2013/02/25 05:04:42 sarrazip Exp $ | |
1 | 1 | .\" BurgerSpace server manual page |
2 | 2 | .\" |
3 | 3 | .\" burgerspace-server - UDP server for networked BurgerSpace |
4 | .\" Copyright (C) 2007-2009 Pierre Sarrazin <http://sarrazip.com/> | |
4 | .\" Copyright (C) 2001-2013 Pierre Sarrazin <http://sarrazip.com/> | |
5 | 5 | .\" |
6 | 6 | .\" This program is free software; you can redistribute it and/or |
7 | 7 | .\" modify it under the terms of the GNU General Public License |
19 | 19 | .\" 02110-1301, USA. |
20 | 20 | .\" |
21 | 21 | .\" |
22 | .TH burgerspace-server "6" "July 14th, 2012" "" "" | |
22 | .TH burgerspace-server "6" "February 25th, 2013" "" "" | |
23 | 23 | .SH NAME |
24 | 24 | burgerspace-server \- UDP server for the networked version of BurgerSpace |
25 | 25 | .SH SYNOPSIS |
0 | .\" $Id: burgerspace-server.6.in,v 1.2 2010/05/26 03:13:01 sarrazip Exp $ | |
0 | .\" $Id: burgerspace-server.6.in,v 1.3 2013/02/25 05:04:42 sarrazip Exp $ | |
1 | 1 | .\" BurgerSpace server manual page |
2 | 2 | .\" |
3 | 3 | .\" burgerspace-server - UDP server for networked BurgerSpace |
4 | .\" Copyright (C) 2007-2009 Pierre Sarrazin <http://sarrazip.com/> | |
4 | .\" Copyright (C) 2001-2013 Pierre Sarrazin <http://sarrazip.com/> | |
5 | 5 | .\" |
6 | 6 | .\" This program is free software; you can redistribute it and/or |
7 | 7 | .\" modify it under the terms of the GNU General Public License |
0 | .\" $Id: burgerspace.6.in,v 1.2 2010/05/26 03:13:01 sarrazip Exp $ | |
0 | .\" $Id: burgerspace.6.in,v 1.3 2013/02/25 05:04:43 sarrazip Exp $ | |
1 | 1 | .\" BurgerSpace manual page |
2 | 2 | .\" |
3 | 3 | .\" burgerspace - A hamburger-smashing video game. |
4 | .\" Copyright (C) 2001-2010 Pierre Sarrazin <http://sarrazip.com/> | |
4 | .\" Copyright (C) 2001-2013 Pierre Sarrazin <http://sarrazip.com/> | |
5 | 5 | .\" |
6 | 6 | .\" This program is free software; you can redistribute it and/or |
7 | 7 | .\" modify it under the terms of the GNU General Public License |
19 | 19 | .\" 02110-1301, USA. |
20 | 20 | .\" |
21 | 21 | .\" |
22 | .TH burgerspace "6" "July 14th, 2012" "" "" | |
22 | .TH burgerspace "6" "February 25th, 2013" "" "" | |
23 | 23 | .SH NAME |
24 | 24 | burgerspace \- A hamburger-smashing video game |
25 | 25 | .SH SYNOPSIS |
0 | .\" $Id: burgerspace.6.in,v 1.2 2010/05/26 03:13:01 sarrazip Exp $ | |
0 | .\" $Id: burgerspace.6.in,v 1.3 2013/02/25 05:04:43 sarrazip Exp $ | |
1 | 1 | .\" BurgerSpace manual page |
2 | 2 | .\" |
3 | 3 | .\" burgerspace - A hamburger-smashing video game. |
4 | .\" Copyright (C) 2001-2010 Pierre Sarrazin <http://sarrazip.com/> | |
4 | .\" Copyright (C) 2001-2013 Pierre Sarrazin <http://sarrazip.com/> | |
5 | 5 | .\" |
6 | 6 | .\" This program is free software; you can redistribute it and/or |
7 | 7 | .\" modify it under the terms of the GNU General Public License |
0 | # Generated from ltmain.m4sh. | |
1 | ||
2 | # libtool (GNU libtool) 2.2.10 | |
0 | ||
1 | # libtool (GNU libtool) 2.4 | |
3 | 2 | # Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996 |
4 | 3 | |
5 | 4 | # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, |
69 | 68 | # compiler: $LTCC |
70 | 69 | # compiler flags: $LTCFLAGS |
71 | 70 | # linker: $LD (gnu? $with_gnu_ld) |
72 | # $progname: (GNU libtool) 2.2.10 | |
71 | # $progname: (GNU libtool) 2.4 | |
73 | 72 | # automake: $automake_version |
74 | 73 | # autoconf: $autoconf_version |
75 | 74 | # |
76 | 75 | # Report bugs to <bug-libtool@gnu.org>. |
76 | # GNU libtool home page: <http://www.gnu.org/software/libtool/>. | |
77 | # General help using GNU software: <http://www.gnu.org/gethelp/>. | |
77 | 78 | |
78 | 79 | PROGRAM=libtool |
79 | 80 | PACKAGE=libtool |
80 | VERSION=2.2.10 | |
81 | VERSION=2.4 | |
81 | 82 | TIMESTAMP="" |
82 | package_revision=1.3175 | |
83 | package_revision=1.3293 | |
83 | 84 | |
84 | 85 | # Be Bourne compatible |
85 | 86 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then |
162 | 163 | dirname="s,/[^/]*$,," |
163 | 164 | basename="s,^.*/,," |
164 | 165 | |
166 | # func_dirname file append nondir_replacement | |
167 | # Compute the dirname of FILE. If nonempty, add APPEND to the result, | |
168 | # otherwise set result to NONDIR_REPLACEMENT. | |
169 | func_dirname () | |
170 | { | |
171 | func_dirname_result=`$ECHO "${1}" | $SED "$dirname"` | |
172 | if test "X$func_dirname_result" = "X${1}"; then | |
173 | func_dirname_result="${3}" | |
174 | else | |
175 | func_dirname_result="$func_dirname_result${2}" | |
176 | fi | |
177 | } # func_dirname may be replaced by extended shell implementation | |
178 | ||
179 | ||
180 | # func_basename file | |
181 | func_basename () | |
182 | { | |
183 | func_basename_result=`$ECHO "${1}" | $SED "$basename"` | |
184 | } # func_basename may be replaced by extended shell implementation | |
185 | ||
186 | ||
165 | 187 | # func_dirname_and_basename file append nondir_replacement |
166 | 188 | # perform func_basename and func_dirname in a single function |
167 | 189 | # call: |
176 | 198 | # those functions but instead duplicate the functionality here. |
177 | 199 | func_dirname_and_basename () |
178 | 200 | { |
179 | # Extract subdirectory from the argument. | |
180 | func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"` | |
181 | if test "X$func_dirname_result" = "X${1}"; then | |
182 | func_dirname_result="${3}" | |
183 | else | |
184 | func_dirname_result="$func_dirname_result${2}" | |
185 | fi | |
186 | func_basename_result=`$ECHO "${1}" | $SED -e "$basename"` | |
187 | } | |
188 | ||
189 | # Generated shell functions inserted here. | |
201 | # Extract subdirectory from the argument. | |
202 | func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"` | |
203 | if test "X$func_dirname_result" = "X${1}"; then | |
204 | func_dirname_result="${3}" | |
205 | else | |
206 | func_dirname_result="$func_dirname_result${2}" | |
207 | fi | |
208 | func_basename_result=`$ECHO "${1}" | $SED -e "$basename"` | |
209 | } # func_dirname_and_basename may be replaced by extended shell implementation | |
210 | ||
211 | ||
212 | # func_stripname prefix suffix name | |
213 | # strip PREFIX and SUFFIX off of NAME. | |
214 | # PREFIX and SUFFIX must not contain globbing or regex special | |
215 | # characters, hashes, percent signs, but SUFFIX may contain a leading | |
216 | # dot (in which case that matches only a dot). | |
217 | # func_strip_suffix prefix name | |
218 | func_stripname () | |
219 | { | |
220 | case ${2} in | |
221 | .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; | |
222 | *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; | |
223 | esac | |
224 | } # func_stripname may be replaced by extended shell implementation | |
225 | ||
190 | 226 | |
191 | 227 | # These SED scripts presuppose an absolute path with a trailing slash. |
192 | 228 | pathcar='s,^/\([^/]*\).*$,\1,' |
369 | 405 | # Same as above, but do not quote variable references. |
370 | 406 | double_quote_subst='s/\(["`\\]\)/\\\1/g' |
371 | 407 | |
408 | # Sed substitution that turns a string into a regex matching for the | |
409 | # string literally. | |
410 | sed_make_literal_regex='s,[].[^$\\*\/],\\&,g' | |
411 | ||
412 | # Sed substitution that converts a w32 file name or path | |
413 | # which contains forward slashes, into one that contains | |
414 | # (escaped) backslashes. A very naive implementation. | |
415 | lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' | |
416 | ||
372 | 417 | # Re-`\' parameter expansions in output of double_quote_subst that were |
373 | 418 | # `\'-ed in input to the same. If an odd number of `\' preceded a '$' |
374 | 419 | # in input to double_quote_subst, that '$' was protected from expansion. |
397 | 442 | # name if it has been set yet. |
398 | 443 | func_echo () |
399 | 444 | { |
400 | $ECHO "$progname${mode+: }$mode: $*" | |
445 | $ECHO "$progname: ${opt_mode+$opt_mode: }$*" | |
401 | 446 | } |
402 | 447 | |
403 | 448 | # func_verbose arg... |
423 | 468 | # Echo program name prefixed message to standard error. |
424 | 469 | func_error () |
425 | 470 | { |
426 | $ECHO "$progname${mode+: }$mode: "${1+"$@"} 1>&2 | |
471 | $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2 | |
427 | 472 | } |
428 | 473 | |
429 | 474 | # func_warning arg... |
430 | 475 | # Echo program name prefixed warning message to standard error. |
431 | 476 | func_warning () |
432 | 477 | { |
433 | $opt_warning && $ECHO "$progname${mode+: }$mode: warning: "${1+"$@"} 1>&2 | |
478 | $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2 | |
434 | 479 | |
435 | 480 | # bash bug again: |
436 | 481 | : |
649 | 694 | fi |
650 | 695 | } |
651 | 696 | |
697 | # func_tr_sh | |
698 | # Turn $1 into a string suitable for a shell variable name. | |
699 | # Result is stored in $func_tr_sh_result. All characters | |
700 | # not in the set a-zA-Z0-9_ are replaced with '_'. Further, | |
701 | # if $1 begins with a digit, a '_' is prepended as well. | |
702 | func_tr_sh () | |
703 | { | |
704 | case $1 in | |
705 | [0-9]* | *[!a-zA-Z0-9_]*) | |
706 | func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'` | |
707 | ;; | |
708 | * ) | |
709 | func_tr_sh_result=$1 | |
710 | ;; | |
711 | esac | |
712 | } | |
713 | ||
652 | 714 | |
653 | 715 | # func_version |
654 | 716 | # Echo version message to standard output and exit. |
655 | 717 | func_version () |
656 | 718 | { |
719 | $opt_debug | |
720 | ||
657 | 721 | $SED -n '/(C)/!b go |
658 | 722 | :more |
659 | 723 | /\./!{ |
675 | 739 | # Echo short help message to standard output and exit. |
676 | 740 | func_usage () |
677 | 741 | { |
742 | $opt_debug | |
743 | ||
678 | 744 | $SED -n '/^# Usage:/,/^# *.*--help/ { |
679 | 745 | s/^# // |
680 | 746 | s/^# *$// |
691 | 757 | # unless 'noexit' is passed as argument. |
692 | 758 | func_help () |
693 | 759 | { |
760 | $opt_debug | |
761 | ||
694 | 762 | $SED -n '/^# Usage:/,/# Report bugs to/ { |
763 | ||
695 | 764 | s/^# // |
696 | 765 | s/^# *$// |
697 | 766 | s*\$progname*'$progname'* |
704 | 773 | s/\$automake_version/'"`(automake --version) 2>/dev/null |$SED 1q`"'/ |
705 | 774 | s/\$autoconf_version/'"`(autoconf --version) 2>/dev/null |$SED 1q`"'/ |
706 | 775 | p |
707 | }' < "$progpath" | |
776 | d | |
777 | } | |
778 | /^# .* home page:/b print | |
779 | /^# General help using/b print | |
780 | ' < "$progpath" | |
708 | 781 | ret=$? |
709 | 782 | if test -z "$1"; then |
710 | 783 | exit $ret |
716 | 789 | # exit_cmd. |
717 | 790 | func_missing_arg () |
718 | 791 | { |
792 | $opt_debug | |
793 | ||
719 | 794 | func_error "missing argument for $1." |
720 | 795 | exit_cmd=exit |
721 | 796 | } |
722 | 797 | |
798 | ||
799 | # func_split_short_opt shortopt | |
800 | # Set func_split_short_opt_name and func_split_short_opt_arg shell | |
801 | # variables after splitting SHORTOPT after the 2nd character. | |
802 | func_split_short_opt () | |
803 | { | |
804 | my_sed_short_opt='1s/^\(..\).*$/\1/;q' | |
805 | my_sed_short_rest='1s/^..\(.*\)$/\1/;q' | |
806 | ||
807 | func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"` | |
808 | func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"` | |
809 | } # func_split_short_opt may be replaced by extended shell implementation | |
810 | ||
811 | ||
812 | # func_split_long_opt longopt | |
813 | # Set func_split_long_opt_name and func_split_long_opt_arg shell | |
814 | # variables after splitting LONGOPT at the `=' sign. | |
815 | func_split_long_opt () | |
816 | { | |
817 | my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q' | |
818 | my_sed_long_arg='1s/^--[^=]*=//' | |
819 | ||
820 | func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"` | |
821 | func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"` | |
822 | } # func_split_long_opt may be replaced by extended shell implementation | |
823 | ||
723 | 824 | exit_cmd=: |
724 | ||
725 | 825 | |
726 | 826 | |
727 | 827 | |
731 | 831 | magic_exe="%%%MAGIC EXE variable%%%" |
732 | 832 | |
733 | 833 | # Global variables. |
734 | # $mode is unset | |
735 | 834 | nonopt= |
736 | execute_dlfiles= | |
737 | 835 | preserve_args= |
738 | 836 | lo2o="s/\\.lo\$/.${objext}/" |
739 | 837 | o2lo="s/\\.${objext}\$/.lo/" |
740 | 838 | extracted_archives= |
741 | 839 | extracted_serial=0 |
742 | 840 | |
743 | opt_dry_run=false | |
744 | opt_duplicate_deps=false | |
745 | opt_silent=false | |
746 | opt_debug=: | |
747 | ||
748 | 841 | # If this variable is set in any of the actions, the command in it |
749 | 842 | # will be execed at the end. This prevents here-documents from being |
750 | 843 | # left over by shells. |
751 | 844 | exec_cmd= |
845 | ||
846 | # func_append var value | |
847 | # Append VALUE to the end of shell variable VAR. | |
848 | func_append () | |
849 | { | |
850 | eval "${1}=\$${1}\${2}" | |
851 | } # func_append may be replaced by extended shell implementation | |
852 | ||
853 | # func_append_quoted var value | |
854 | # Quote VALUE and append to the end of shell variable VAR, separated | |
855 | # by a space. | |
856 | func_append_quoted () | |
857 | { | |
858 | func_quote_for_eval "${2}" | |
859 | eval "${1}=\$${1}\\ \$func_quote_for_eval_result" | |
860 | } # func_append_quoted may be replaced by extended shell implementation | |
861 | ||
862 | ||
863 | # func_arith arithmetic-term... | |
864 | func_arith () | |
865 | { | |
866 | func_arith_result=`expr "${@}"` | |
867 | } # func_arith may be replaced by extended shell implementation | |
868 | ||
869 | ||
870 | # func_len string | |
871 | # STRING may not start with a hyphen. | |
872 | func_len () | |
873 | { | |
874 | func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len` | |
875 | } # func_len may be replaced by extended shell implementation | |
876 | ||
877 | ||
878 | # func_lo2o object | |
879 | func_lo2o () | |
880 | { | |
881 | func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` | |
882 | } # func_lo2o may be replaced by extended shell implementation | |
883 | ||
884 | ||
885 | # func_xform libobj-or-source | |
886 | func_xform () | |
887 | { | |
888 | func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'` | |
889 | } # func_xform may be replaced by extended shell implementation | |
890 | ||
752 | 891 | |
753 | 892 | # func_fatal_configuration arg... |
754 | 893 | # Echo program name prefixed message to standard error, followed by |
837 | 976 | fi |
838 | 977 | ;; |
839 | 978 | esac |
840 | } | |
841 | ||
842 | # Parse options once, thoroughly. This comes as soon as possible in | |
843 | # the script to make things like `libtool --version' happen quickly. | |
844 | { | |
845 | ||
846 | # Shorthand for --mode=foo, only valid as the first argument | |
847 | case $1 in | |
848 | clean|clea|cle|cl) | |
849 | shift; set dummy --mode clean ${1+"$@"}; shift | |
850 | ;; | |
851 | compile|compil|compi|comp|com|co|c) | |
852 | shift; set dummy --mode compile ${1+"$@"}; shift | |
853 | ;; | |
854 | execute|execut|execu|exec|exe|ex|e) | |
855 | shift; set dummy --mode execute ${1+"$@"}; shift | |
856 | ;; | |
857 | finish|finis|fini|fin|fi|f) | |
858 | shift; set dummy --mode finish ${1+"$@"}; shift | |
859 | ;; | |
860 | install|instal|insta|inst|ins|in|i) | |
861 | shift; set dummy --mode install ${1+"$@"}; shift | |
862 | ;; | |
863 | link|lin|li|l) | |
864 | shift; set dummy --mode link ${1+"$@"}; shift | |
865 | ;; | |
866 | uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) | |
867 | shift; set dummy --mode uninstall ${1+"$@"}; shift | |
868 | ;; | |
869 | esac | |
870 | ||
871 | # Parse non-mode specific arguments: | |
872 | while test "$#" -gt 0; do | |
873 | opt="$1" | |
874 | shift | |
875 | ||
876 | case $opt in | |
877 | --config) func_config ;; | |
878 | ||
879 | --debug) preserve_args="$preserve_args $opt" | |
880 | func_echo "enabling shell trace mode" | |
881 | opt_debug='set -x' | |
882 | $opt_debug | |
883 | ;; | |
884 | ||
885 | -dlopen) test "$#" -eq 0 && func_missing_arg "$opt" && break | |
886 | execute_dlfiles="$execute_dlfiles $1" | |
887 | shift | |
888 | ;; | |
889 | ||
890 | --dry-run | -n) opt_dry_run=: ;; | |
891 | --features) func_features ;; | |
892 | --finish) mode="finish" ;; | |
893 | ||
894 | --mode) test "$#" -eq 0 && func_missing_arg "$opt" && break | |
895 | case $1 in | |
896 | # Valid mode arguments: | |
897 | clean) ;; | |
898 | compile) ;; | |
899 | execute) ;; | |
900 | finish) ;; | |
901 | install) ;; | |
902 | link) ;; | |
903 | relink) ;; | |
904 | uninstall) ;; | |
905 | ||
906 | # Catch anything else as an error | |
907 | *) func_error "invalid argument for $opt" | |
908 | exit_cmd=exit | |
909 | break | |
910 | ;; | |
911 | esac | |
912 | ||
913 | mode="$1" | |
914 | shift | |
915 | ;; | |
916 | ||
917 | --preserve-dup-deps) | |
918 | opt_duplicate_deps=: ;; | |
919 | ||
920 | --quiet|--silent) preserve_args="$preserve_args $opt" | |
921 | opt_silent=: | |
922 | opt_verbose=false | |
923 | ;; | |
924 | ||
925 | --no-quiet|--no-silent) | |
926 | preserve_args="$preserve_args $opt" | |
927 | opt_silent=false | |
928 | ;; | |
929 | ||
930 | --verbose| -v) preserve_args="$preserve_args $opt" | |
931 | opt_silent=false | |
932 | opt_verbose=: | |
933 | ;; | |
934 | ||
935 | --no-verbose) preserve_args="$preserve_args $opt" | |
936 | opt_verbose=false | |
937 | ;; | |
938 | ||
939 | --tag) test "$#" -eq 0 && func_missing_arg "$opt" && break | |
940 | preserve_args="$preserve_args $opt $1" | |
941 | func_enable_tag "$1" # tagname is set here | |
942 | shift | |
943 | ;; | |
944 | ||
945 | # Separate optargs to long options: | |
946 | -dlopen=*|--mode=*|--tag=*) | |
947 | func_opt_split "$opt" | |
948 | set dummy "$func_opt_split_opt" "$func_opt_split_arg" ${1+"$@"} | |
949 | shift | |
950 | ;; | |
951 | ||
952 | -\?|-h) func_usage ;; | |
953 | --help) opt_help=: ;; | |
954 | --help-all) opt_help=': help-all' ;; | |
955 | --version) func_version ;; | |
956 | ||
957 | -*) func_fatal_help "unrecognized option \`$opt'" ;; | |
958 | ||
959 | *) nonopt="$opt" | |
960 | break | |
961 | ;; | |
962 | esac | |
963 | done | |
964 | ||
965 | ||
966 | case $host in | |
967 | *cygwin* | *mingw* | *pw32* | *cegcc*) | |
968 | # don't eliminate duplications in $postdeps and $predeps | |
969 | opt_duplicate_compiler_generated_deps=: | |
970 | ;; | |
971 | *) | |
972 | opt_duplicate_compiler_generated_deps=$opt_duplicate_deps | |
973 | ;; | |
974 | esac | |
975 | ||
976 | # Having warned about all mis-specified options, bail out if | |
977 | # anything was wrong. | |
978 | $exit_cmd $EXIT_FAILURE | |
979 | 979 | } |
980 | 980 | |
981 | 981 | # func_check_version_match |
1014 | 1014 | } |
1015 | 1015 | |
1016 | 1016 | |
1017 | # Shorthand for --mode=foo, only valid as the first argument | |
1018 | case $1 in | |
1019 | clean|clea|cle|cl) | |
1020 | shift; set dummy --mode clean ${1+"$@"}; shift | |
1021 | ;; | |
1022 | compile|compil|compi|comp|com|co|c) | |
1023 | shift; set dummy --mode compile ${1+"$@"}; shift | |
1024 | ;; | |
1025 | execute|execut|execu|exec|exe|ex|e) | |
1026 | shift; set dummy --mode execute ${1+"$@"}; shift | |
1027 | ;; | |
1028 | finish|finis|fini|fin|fi|f) | |
1029 | shift; set dummy --mode finish ${1+"$@"}; shift | |
1030 | ;; | |
1031 | install|instal|insta|inst|ins|in|i) | |
1032 | shift; set dummy --mode install ${1+"$@"}; shift | |
1033 | ;; | |
1034 | link|lin|li|l) | |
1035 | shift; set dummy --mode link ${1+"$@"}; shift | |
1036 | ;; | |
1037 | uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) | |
1038 | shift; set dummy --mode uninstall ${1+"$@"}; shift | |
1039 | ;; | |
1040 | esac | |
1041 | ||
1042 | ||
1043 | ||
1044 | # Option defaults: | |
1045 | opt_debug=: | |
1046 | opt_dry_run=false | |
1047 | opt_config=false | |
1048 | opt_preserve_dup_deps=false | |
1049 | opt_features=false | |
1050 | opt_finish=false | |
1051 | opt_help=false | |
1052 | opt_help_all=false | |
1053 | opt_silent=: | |
1054 | opt_verbose=: | |
1055 | opt_silent=false | |
1056 | opt_verbose=false | |
1057 | ||
1058 | ||
1059 | # Parse options once, thoroughly. This comes as soon as possible in the | |
1060 | # script to make things like `--version' happen as quickly as we can. | |
1061 | { | |
1062 | # this just eases exit handling | |
1063 | while test $# -gt 0; do | |
1064 | opt="$1" | |
1065 | shift | |
1066 | case $opt in | |
1067 | --debug|-x) opt_debug='set -x' | |
1068 | func_echo "enabling shell trace mode" | |
1069 | $opt_debug | |
1070 | ;; | |
1071 | --dry-run|--dryrun|-n) | |
1072 | opt_dry_run=: | |
1073 | ;; | |
1074 | --config) | |
1075 | opt_config=: | |
1076 | func_config | |
1077 | ;; | |
1078 | --dlopen|-dlopen) | |
1079 | optarg="$1" | |
1080 | opt_dlopen="${opt_dlopen+$opt_dlopen | |
1081 | }$optarg" | |
1082 | shift | |
1083 | ;; | |
1084 | --preserve-dup-deps) | |
1085 | opt_preserve_dup_deps=: | |
1086 | ;; | |
1087 | --features) | |
1088 | opt_features=: | |
1089 | func_features | |
1090 | ;; | |
1091 | --finish) | |
1092 | opt_finish=: | |
1093 | set dummy --mode finish ${1+"$@"}; shift | |
1094 | ;; | |
1095 | --help) | |
1096 | opt_help=: | |
1097 | ;; | |
1098 | --help-all) | |
1099 | opt_help_all=: | |
1100 | opt_help=': help-all' | |
1101 | ;; | |
1102 | --mode) | |
1103 | test $# = 0 && func_missing_arg $opt && break | |
1104 | optarg="$1" | |
1105 | opt_mode="$optarg" | |
1106 | case $optarg in | |
1107 | # Valid mode arguments: | |
1108 | clean|compile|execute|finish|install|link|relink|uninstall) ;; | |
1109 | ||
1110 | # Catch anything else as an error | |
1111 | *) func_error "invalid argument for $opt" | |
1112 | exit_cmd=exit | |
1113 | break | |
1114 | ;; | |
1115 | esac | |
1116 | shift | |
1117 | ;; | |
1118 | --no-silent|--no-quiet) | |
1119 | opt_silent=false | |
1120 | func_append preserve_args " $opt" | |
1121 | ;; | |
1122 | --no-verbose) | |
1123 | opt_verbose=false | |
1124 | func_append preserve_args " $opt" | |
1125 | ;; | |
1126 | --silent|--quiet) | |
1127 | opt_silent=: | |
1128 | func_append preserve_args " $opt" | |
1129 | opt_verbose=false | |
1130 | ;; | |
1131 | --verbose|-v) | |
1132 | opt_verbose=: | |
1133 | func_append preserve_args " $opt" | |
1134 | opt_silent=false | |
1135 | ;; | |
1136 | --tag) | |
1137 | test $# = 0 && func_missing_arg $opt && break | |
1138 | optarg="$1" | |
1139 | opt_tag="$optarg" | |
1140 | func_append preserve_args " $opt $optarg" | |
1141 | func_enable_tag "$optarg" | |
1142 | shift | |
1143 | ;; | |
1144 | ||
1145 | -\?|-h) func_usage ;; | |
1146 | --help) func_help ;; | |
1147 | --version) func_version ;; | |
1148 | ||
1149 | # Separate optargs to long options: | |
1150 | --*=*) | |
1151 | func_split_long_opt "$opt" | |
1152 | set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"} | |
1153 | shift | |
1154 | ;; | |
1155 | ||
1156 | # Separate non-argument short options: | |
1157 | -\?*|-h*|-n*|-v*) | |
1158 | func_split_short_opt "$opt" | |
1159 | set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"} | |
1160 | shift | |
1161 | ;; | |
1162 | ||
1163 | --) break ;; | |
1164 | -*) func_fatal_help "unrecognized option \`$opt'" ;; | |
1165 | *) set dummy "$opt" ${1+"$@"}; shift; break ;; | |
1166 | esac | |
1167 | done | |
1168 | ||
1169 | # Validate options: | |
1170 | ||
1171 | # save first non-option argument | |
1172 | if test "$#" -gt 0; then | |
1173 | nonopt="$opt" | |
1174 | shift | |
1175 | fi | |
1176 | ||
1177 | # preserve --debug | |
1178 | test "$opt_debug" = : || func_append preserve_args " --debug" | |
1179 | ||
1180 | case $host in | |
1181 | *cygwin* | *mingw* | *pw32* | *cegcc*) | |
1182 | # don't eliminate duplications in $postdeps and $predeps | |
1183 | opt_duplicate_compiler_generated_deps=: | |
1184 | ;; | |
1185 | *) | |
1186 | opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps | |
1187 | ;; | |
1188 | esac | |
1189 | ||
1190 | $opt_help || { | |
1191 | # Sanity checks first: | |
1192 | func_check_version_match | |
1193 | ||
1194 | if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then | |
1195 | func_fatal_configuration "not configured to build any kind of library" | |
1196 | fi | |
1197 | ||
1198 | # Darwin sucks | |
1199 | eval std_shrext=\"$shrext_cmds\" | |
1200 | ||
1201 | # Only execute mode is allowed to have -dlopen flags. | |
1202 | if test -n "$opt_dlopen" && test "$opt_mode" != execute; then | |
1203 | func_error "unrecognized option \`-dlopen'" | |
1204 | $ECHO "$help" 1>&2 | |
1205 | exit $EXIT_FAILURE | |
1206 | fi | |
1207 | ||
1208 | # Change the help message to a mode-specific one. | |
1209 | generic_help="$help" | |
1210 | help="Try \`$progname --help --mode=$opt_mode' for more information." | |
1211 | } | |
1212 | ||
1213 | ||
1214 | # Bail if the options were screwed | |
1215 | $exit_cmd $EXIT_FAILURE | |
1216 | } | |
1217 | ||
1218 | ||
1219 | ||
1220 | ||
1017 | 1221 | ## ----------- ## |
1018 | 1222 | ## Main. ## |
1019 | 1223 | ## ----------- ## |
1020 | ||
1021 | $opt_help || { | |
1022 | # Sanity checks first: | |
1023 | func_check_version_match | |
1024 | ||
1025 | if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then | |
1026 | func_fatal_configuration "not configured to build any kind of library" | |
1027 | fi | |
1028 | ||
1029 | test -z "$mode" && func_fatal_error "error: you must specify a MODE." | |
1030 | ||
1031 | ||
1032 | # Darwin sucks | |
1033 | eval std_shrext=\"$shrext_cmds\" | |
1034 | ||
1035 | ||
1036 | # Only execute mode is allowed to have -dlopen flags. | |
1037 | if test -n "$execute_dlfiles" && test "$mode" != execute; then | |
1038 | func_error "unrecognized option \`-dlopen'" | |
1039 | $ECHO "$help" 1>&2 | |
1040 | exit $EXIT_FAILURE | |
1041 | fi | |
1042 | ||
1043 | # Change the help message to a mode-specific one. | |
1044 | generic_help="$help" | |
1045 | help="Try \`$progname --help --mode=$mode' for more information." | |
1046 | } | |
1047 | ||
1048 | 1224 | |
1049 | 1225 | # func_lalib_p file |
1050 | 1226 | # True iff FILE is a libtool `.la' library or `.lo' object file. |
1109 | 1285 | # temporary ltwrapper_script. |
1110 | 1286 | func_ltwrapper_scriptname () |
1111 | 1287 | { |
1112 | func_ltwrapper_scriptname_result="" | |
1113 | if func_ltwrapper_executable_p "$1"; then | |
1114 | func_dirname_and_basename "$1" "" "." | |
1115 | func_stripname '' '.exe' "$func_basename_result" | |
1116 | func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper" | |
1117 | fi | |
1288 | func_dirname_and_basename "$1" "" "." | |
1289 | func_stripname '' '.exe' "$func_basename_result" | |
1290 | func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper" | |
1118 | 1291 | } |
1119 | 1292 | |
1120 | 1293 | # func_ltwrapper_p file |
1160 | 1333 | } |
1161 | 1334 | |
1162 | 1335 | |
1336 | # func_resolve_sysroot PATH | |
1337 | # Replace a leading = in PATH with a sysroot. Store the result into | |
1338 | # func_resolve_sysroot_result | |
1339 | func_resolve_sysroot () | |
1340 | { | |
1341 | func_resolve_sysroot_result=$1 | |
1342 | case $func_resolve_sysroot_result in | |
1343 | =*) | |
1344 | func_stripname '=' '' "$func_resolve_sysroot_result" | |
1345 | func_resolve_sysroot_result=$lt_sysroot$func_stripname_result | |
1346 | ;; | |
1347 | esac | |
1348 | } | |
1349 | ||
1350 | # func_replace_sysroot PATH | |
1351 | # If PATH begins with the sysroot, replace it with = and | |
1352 | # store the result into func_replace_sysroot_result. | |
1353 | func_replace_sysroot () | |
1354 | { | |
1355 | case "$lt_sysroot:$1" in | |
1356 | ?*:"$lt_sysroot"*) | |
1357 | func_stripname "$lt_sysroot" '' "$1" | |
1358 | func_replace_sysroot_result="=$func_stripname_result" | |
1359 | ;; | |
1360 | *) | |
1361 | # Including no sysroot. | |
1362 | func_replace_sysroot_result=$1 | |
1363 | ;; | |
1364 | esac | |
1365 | } | |
1366 | ||
1163 | 1367 | # func_infer_tag arg |
1164 | 1368 | # Infer tagged configuration to use if any are available and |
1165 | 1369 | # if one wasn't chosen via the "--tag" command line option. |
1172 | 1376 | if test -n "$available_tags" && test -z "$tagname"; then |
1173 | 1377 | CC_quoted= |
1174 | 1378 | for arg in $CC; do |
1175 | func_quote_for_eval "$arg" | |
1176 | CC_quoted="$CC_quoted $func_quote_for_eval_result" | |
1379 | func_append_quoted CC_quoted "$arg" | |
1177 | 1380 | done |
1178 | 1381 | CC_expanded=`func_echo_all $CC` |
1179 | 1382 | CC_quoted_expanded=`func_echo_all $CC_quoted` |
1192 | 1395 | CC_quoted= |
1193 | 1396 | for arg in $CC; do |
1194 | 1397 | # Double-quote args containing other shell metacharacters. |
1195 | func_quote_for_eval "$arg" | |
1196 | CC_quoted="$CC_quoted $func_quote_for_eval_result" | |
1398 | func_append_quoted CC_quoted "$arg" | |
1197 | 1399 | done |
1198 | 1400 | CC_expanded=`func_echo_all $CC` |
1199 | 1401 | CC_quoted_expanded=`func_echo_all $CC_quoted` |
1262 | 1464 | } |
1263 | 1465 | } |
1264 | 1466 | |
1467 | ||
1468 | ################################################## | |
1469 | # FILE NAME AND PATH CONVERSION HELPER FUNCTIONS # | |
1470 | ################################################## | |
1471 | ||
1472 | # func_convert_core_file_wine_to_w32 ARG | |
1473 | # Helper function used by file name conversion functions when $build is *nix, | |
1474 | # and $host is mingw, cygwin, or some other w32 environment. Relies on a | |
1475 | # correctly configured wine environment available, with the winepath program | |
1476 | # in $build's $PATH. | |
1477 | # | |
1478 | # ARG is the $build file name to be converted to w32 format. | |
1479 | # Result is available in $func_convert_core_file_wine_to_w32_result, and will | |
1480 | # be empty on error (or when ARG is empty) | |
1481 | func_convert_core_file_wine_to_w32 () | |
1482 | { | |
1483 | $opt_debug | |
1484 | func_convert_core_file_wine_to_w32_result="$1" | |
1485 | if test -n "$1"; then | |
1486 | # Unfortunately, winepath does not exit with a non-zero error code, so we | |
1487 | # are forced to check the contents of stdout. On the other hand, if the | |
1488 | # command is not found, the shell will set an exit code of 127 and print | |
1489 | # *an error message* to stdout. So we must check for both error code of | |
1490 | # zero AND non-empty stdout, which explains the odd construction: | |
1491 | func_convert_core_file_wine_to_w32_tmp=`winepath -w "$1" 2>/dev/null` | |
1492 | if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then | |
1493 | func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | | |
1494 | $SED -e "$lt_sed_naive_backslashify"` | |
1495 | else | |
1496 | func_convert_core_file_wine_to_w32_result= | |
1497 | fi | |
1498 | fi | |
1499 | } | |
1500 | # end: func_convert_core_file_wine_to_w32 | |
1501 | ||
1502 | ||
1503 | # func_convert_core_path_wine_to_w32 ARG | |
1504 | # Helper function used by path conversion functions when $build is *nix, and | |
1505 | # $host is mingw, cygwin, or some other w32 environment. Relies on a correctly | |
1506 | # configured wine environment available, with the winepath program in $build's | |
1507 | # $PATH. Assumes ARG has no leading or trailing path separator characters. | |
1508 | # | |
1509 | # ARG is path to be converted from $build format to win32. | |
1510 | # Result is available in $func_convert_core_path_wine_to_w32_result. | |
1511 | # Unconvertible file (directory) names in ARG are skipped; if no directory names | |
1512 | # are convertible, then the result may be empty. | |
1513 | func_convert_core_path_wine_to_w32 () | |
1514 | { | |
1515 | $opt_debug | |
1516 | # unfortunately, winepath doesn't convert paths, only file names | |
1517 | func_convert_core_path_wine_to_w32_result="" | |
1518 | if test -n "$1"; then | |
1519 | oldIFS=$IFS | |
1520 | IFS=: | |
1521 | for func_convert_core_path_wine_to_w32_f in $1; do | |
1522 | IFS=$oldIFS | |
1523 | func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" | |
1524 | if test -n "$func_convert_core_file_wine_to_w32_result" ; then | |
1525 | if test -z "$func_convert_core_path_wine_to_w32_result"; then | |
1526 | func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result" | |
1527 | else | |
1528 | func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" | |
1529 | fi | |
1530 | fi | |
1531 | done | |
1532 | IFS=$oldIFS | |
1533 | fi | |
1534 | } | |
1535 | # end: func_convert_core_path_wine_to_w32 | |
1536 | ||
1537 | ||
1538 | # func_cygpath ARGS... | |
1539 | # Wrapper around calling the cygpath program via LT_CYGPATH. This is used when | |
1540 | # when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) | |
1541 | # $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or | |
1542 | # (2), returns the Cygwin file name or path in func_cygpath_result (input | |
1543 | # file name or path is assumed to be in w32 format, as previously converted | |
1544 | # from $build's *nix or MSYS format). In case (3), returns the w32 file name | |
1545 | # or path in func_cygpath_result (input file name or path is assumed to be in | |
1546 | # Cygwin format). Returns an empty string on error. | |
1547 | # | |
1548 | # ARGS are passed to cygpath, with the last one being the file name or path to | |
1549 | # be converted. | |
1550 | # | |
1551 | # Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH | |
1552 | # environment variable; do not put it in $PATH. | |
1553 | func_cygpath () | |
1554 | { | |
1555 | $opt_debug | |
1556 | if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then | |
1557 | func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` | |
1558 | if test "$?" -ne 0; then | |
1559 | # on failure, ensure result is empty | |
1560 | func_cygpath_result= | |
1561 | fi | |
1562 | else | |
1563 | func_cygpath_result= | |
1564 | func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'" | |
1565 | fi | |
1566 | } | |
1567 | #end: func_cygpath | |
1568 | ||
1569 | ||
1570 | # func_convert_core_msys_to_w32 ARG | |
1571 | # Convert file name or path ARG from MSYS format to w32 format. Return | |
1572 | # result in func_convert_core_msys_to_w32_result. | |
1573 | func_convert_core_msys_to_w32 () | |
1574 | { | |
1575 | $opt_debug | |
1576 | # awkward: cmd appends spaces to result | |
1577 | func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | | |
1578 | $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"` | |
1579 | } | |
1580 | #end: func_convert_core_msys_to_w32 | |
1581 | ||
1582 | ||
1583 | # func_convert_file_check ARG1 ARG2 | |
1584 | # Verify that ARG1 (a file name in $build format) was converted to $host | |
1585 | # format in ARG2. Otherwise, emit an error message, but continue (resetting | |
1586 | # func_to_host_file_result to ARG1). | |
1587 | func_convert_file_check () | |
1588 | { | |
1589 | $opt_debug | |
1590 | if test -z "$2" && test -n "$1" ; then | |
1591 | func_error "Could not determine host file name corresponding to" | |
1592 | func_error " \`$1'" | |
1593 | func_error "Continuing, but uninstalled executables may not work." | |
1594 | # Fallback: | |
1595 | func_to_host_file_result="$1" | |
1596 | fi | |
1597 | } | |
1598 | # end func_convert_file_check | |
1599 | ||
1600 | ||
1601 | # func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH | |
1602 | # Verify that FROM_PATH (a path in $build format) was converted to $host | |
1603 | # format in TO_PATH. Otherwise, emit an error message, but continue, resetting | |
1604 | # func_to_host_file_result to a simplistic fallback value (see below). | |
1605 | func_convert_path_check () | |
1606 | { | |
1607 | $opt_debug | |
1608 | if test -z "$4" && test -n "$3"; then | |
1609 | func_error "Could not determine the host path corresponding to" | |
1610 | func_error " \`$3'" | |
1611 | func_error "Continuing, but uninstalled executables may not work." | |
1612 | # Fallback. This is a deliberately simplistic "conversion" and | |
1613 | # should not be "improved". See libtool.info. | |
1614 | if test "x$1" != "x$2"; then | |
1615 | lt_replace_pathsep_chars="s|$1|$2|g" | |
1616 | func_to_host_path_result=`echo "$3" | | |
1617 | $SED -e "$lt_replace_pathsep_chars"` | |
1618 | else | |
1619 | func_to_host_path_result="$3" | |
1620 | fi | |
1621 | fi | |
1622 | } | |
1623 | # end func_convert_path_check | |
1624 | ||
1625 | ||
1626 | # func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG | |
1627 | # Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT | |
1628 | # and appending REPL if ORIG matches BACKPAT. | |
1629 | func_convert_path_front_back_pathsep () | |
1630 | { | |
1631 | $opt_debug | |
1632 | case $4 in | |
1633 | $1 ) func_to_host_path_result="$3$func_to_host_path_result" | |
1634 | ;; | |
1635 | esac | |
1636 | case $4 in | |
1637 | $2 ) func_append func_to_host_path_result "$3" | |
1638 | ;; | |
1639 | esac | |
1640 | } | |
1641 | # end func_convert_path_front_back_pathsep | |
1642 | ||
1643 | ||
1644 | ################################################## | |
1645 | # $build to $host FILE NAME CONVERSION FUNCTIONS # | |
1646 | ################################################## | |
1647 | # invoked via `$to_host_file_cmd ARG' | |
1648 | # | |
1649 | # In each case, ARG is the path to be converted from $build to $host format. | |
1650 | # Result will be available in $func_to_host_file_result. | |
1651 | ||
1652 | ||
1653 | # func_to_host_file ARG | |
1654 | # Converts the file name ARG from $build format to $host format. Return result | |
1655 | # in func_to_host_file_result. | |
1656 | func_to_host_file () | |
1657 | { | |
1658 | $opt_debug | |
1659 | $to_host_file_cmd "$1" | |
1660 | } | |
1661 | # end func_to_host_file | |
1662 | ||
1663 | ||
1664 | # func_to_tool_file ARG LAZY | |
1665 | # converts the file name ARG from $build format to toolchain format. Return | |
1666 | # result in func_to_tool_file_result. If the conversion in use is listed | |
1667 | # in (the comma separated) LAZY, no conversion takes place. | |
1668 | func_to_tool_file () | |
1669 | { | |
1670 | $opt_debug | |
1671 | case ,$2, in | |
1672 | *,"$to_tool_file_cmd",*) | |
1673 | func_to_tool_file_result=$1 | |
1674 | ;; | |
1675 | *) | |
1676 | $to_tool_file_cmd "$1" | |
1677 | func_to_tool_file_result=$func_to_host_file_result | |
1678 | ;; | |
1679 | esac | |
1680 | } | |
1681 | # end func_to_tool_file | |
1682 | ||
1683 | ||
1684 | # func_convert_file_noop ARG | |
1685 | # Copy ARG to func_to_host_file_result. | |
1686 | func_convert_file_noop () | |
1687 | { | |
1688 | func_to_host_file_result="$1" | |
1689 | } | |
1690 | # end func_convert_file_noop | |
1691 | ||
1692 | ||
1693 | # func_convert_file_msys_to_w32 ARG | |
1694 | # Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic | |
1695 | # conversion to w32 is not available inside the cwrapper. Returns result in | |
1696 | # func_to_host_file_result. | |
1697 | func_convert_file_msys_to_w32 () | |
1698 | { | |
1699 | $opt_debug | |
1700 | func_to_host_file_result="$1" | |
1701 | if test -n "$1"; then | |
1702 | func_convert_core_msys_to_w32 "$1" | |
1703 | func_to_host_file_result="$func_convert_core_msys_to_w32_result" | |
1704 | fi | |
1705 | func_convert_file_check "$1" "$func_to_host_file_result" | |
1706 | } | |
1707 | # end func_convert_file_msys_to_w32 | |
1708 | ||
1709 | ||
1710 | # func_convert_file_cygwin_to_w32 ARG | |
1711 | # Convert file name ARG from Cygwin to w32 format. Returns result in | |
1712 | # func_to_host_file_result. | |
1713 | func_convert_file_cygwin_to_w32 () | |
1714 | { | |
1715 | $opt_debug | |
1716 | func_to_host_file_result="$1" | |
1717 | if test -n "$1"; then | |
1718 | # because $build is cygwin, we call "the" cygpath in $PATH; no need to use | |
1719 | # LT_CYGPATH in this case. | |
1720 | func_to_host_file_result=`cygpath -m "$1"` | |
1721 | fi | |
1722 | func_convert_file_check "$1" "$func_to_host_file_result" | |
1723 | } | |
1724 | # end func_convert_file_cygwin_to_w32 | |
1725 | ||
1726 | ||
1727 | # func_convert_file_nix_to_w32 ARG | |
1728 | # Convert file name ARG from *nix to w32 format. Requires a wine environment | |
1729 | # and a working winepath. Returns result in func_to_host_file_result. | |
1730 | func_convert_file_nix_to_w32 () | |
1731 | { | |
1732 | $opt_debug | |
1733 | func_to_host_file_result="$1" | |
1734 | if test -n "$1"; then | |
1735 | func_convert_core_file_wine_to_w32 "$1" | |
1736 | func_to_host_file_result="$func_convert_core_file_wine_to_w32_result" | |
1737 | fi | |
1738 | func_convert_file_check "$1" "$func_to_host_file_result" | |
1739 | } | |
1740 | # end func_convert_file_nix_to_w32 | |
1741 | ||
1742 | ||
1743 | # func_convert_file_msys_to_cygwin ARG | |
1744 | # Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. | |
1745 | # Returns result in func_to_host_file_result. | |
1746 | func_convert_file_msys_to_cygwin () | |
1747 | { | |
1748 | $opt_debug | |
1749 | func_to_host_file_result="$1" | |
1750 | if test -n "$1"; then | |
1751 | func_convert_core_msys_to_w32 "$1" | |
1752 | func_cygpath -u "$func_convert_core_msys_to_w32_result" | |
1753 | func_to_host_file_result="$func_cygpath_result" | |
1754 | fi | |
1755 | func_convert_file_check "$1" "$func_to_host_file_result" | |
1756 | } | |
1757 | # end func_convert_file_msys_to_cygwin | |
1758 | ||
1759 | ||
1760 | # func_convert_file_nix_to_cygwin ARG | |
1761 | # Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed | |
1762 | # in a wine environment, working winepath, and LT_CYGPATH set. Returns result | |
1763 | # in func_to_host_file_result. | |
1764 | func_convert_file_nix_to_cygwin () | |
1765 | { | |
1766 | $opt_debug | |
1767 | func_to_host_file_result="$1" | |
1768 | if test -n "$1"; then | |
1769 | # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. | |
1770 | func_convert_core_file_wine_to_w32 "$1" | |
1771 | func_cygpath -u "$func_convert_core_file_wine_to_w32_result" | |
1772 | func_to_host_file_result="$func_cygpath_result" | |
1773 | fi | |
1774 | func_convert_file_check "$1" "$func_to_host_file_result" | |
1775 | } | |
1776 | # end func_convert_file_nix_to_cygwin | |
1777 | ||
1778 | ||
1779 | ############################################# | |
1780 | # $build to $host PATH CONVERSION FUNCTIONS # | |
1781 | ############################################# | |
1782 | # invoked via `$to_host_path_cmd ARG' | |
1783 | # | |
1784 | # In each case, ARG is the path to be converted from $build to $host format. | |
1785 | # The result will be available in $func_to_host_path_result. | |
1786 | # | |
1787 | # Path separators are also converted from $build format to $host format. If | |
1788 | # ARG begins or ends with a path separator character, it is preserved (but | |
1789 | # converted to $host format) on output. | |
1790 | # | |
1791 | # All path conversion functions are named using the following convention: | |
1792 | # file name conversion function : func_convert_file_X_to_Y () | |
1793 | # path conversion function : func_convert_path_X_to_Y () | |
1794 | # where, for any given $build/$host combination the 'X_to_Y' value is the | |
1795 | # same. If conversion functions are added for new $build/$host combinations, | |
1796 | # the two new functions must follow this pattern, or func_init_to_host_path_cmd | |
1797 | # will break. | |
1798 | ||
1799 | ||
1800 | # func_init_to_host_path_cmd | |
1801 | # Ensures that function "pointer" variable $to_host_path_cmd is set to the | |
1802 | # appropriate value, based on the value of $to_host_file_cmd. | |
1803 | to_host_path_cmd= | |
1804 | func_init_to_host_path_cmd () | |
1805 | { | |
1806 | $opt_debug | |
1807 | if test -z "$to_host_path_cmd"; then | |
1808 | func_stripname 'func_convert_file_' '' "$to_host_file_cmd" | |
1809 | to_host_path_cmd="func_convert_path_${func_stripname_result}" | |
1810 | fi | |
1811 | } | |
1812 | ||
1813 | ||
1814 | # func_to_host_path ARG | |
1815 | # Converts the path ARG from $build format to $host format. Return result | |
1816 | # in func_to_host_path_result. | |
1817 | func_to_host_path () | |
1818 | { | |
1819 | $opt_debug | |
1820 | func_init_to_host_path_cmd | |
1821 | $to_host_path_cmd "$1" | |
1822 | } | |
1823 | # end func_to_host_path | |
1824 | ||
1825 | ||
1826 | # func_convert_path_noop ARG | |
1827 | # Copy ARG to func_to_host_path_result. | |
1828 | func_convert_path_noop () | |
1829 | { | |
1830 | func_to_host_path_result="$1" | |
1831 | } | |
1832 | # end func_convert_path_noop | |
1833 | ||
1834 | ||
1835 | # func_convert_path_msys_to_w32 ARG | |
1836 | # Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic | |
1837 | # conversion to w32 is not available inside the cwrapper. Returns result in | |
1838 | # func_to_host_path_result. | |
1839 | func_convert_path_msys_to_w32 () | |
1840 | { | |
1841 | $opt_debug | |
1842 | func_to_host_path_result="$1" | |
1843 | if test -n "$1"; then | |
1844 | # Remove leading and trailing path separator characters from ARG. MSYS | |
1845 | # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; | |
1846 | # and winepath ignores them completely. | |
1847 | func_stripname : : "$1" | |
1848 | func_to_host_path_tmp1=$func_stripname_result | |
1849 | func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" | |
1850 | func_to_host_path_result="$func_convert_core_msys_to_w32_result" | |
1851 | func_convert_path_check : ";" \ | |
1852 | "$func_to_host_path_tmp1" "$func_to_host_path_result" | |
1853 | func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" | |
1854 | fi | |
1855 | } | |
1856 | # end func_convert_path_msys_to_w32 | |
1857 | ||
1858 | ||
1859 | # func_convert_path_cygwin_to_w32 ARG | |
1860 | # Convert path ARG from Cygwin to w32 format. Returns result in | |
1861 | # func_to_host_file_result. | |
1862 | func_convert_path_cygwin_to_w32 () | |
1863 | { | |
1864 | $opt_debug | |
1865 | func_to_host_path_result="$1" | |
1866 | if test -n "$1"; then | |
1867 | # See func_convert_path_msys_to_w32: | |
1868 | func_stripname : : "$1" | |
1869 | func_to_host_path_tmp1=$func_stripname_result | |
1870 | func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` | |
1871 | func_convert_path_check : ";" \ | |
1872 | "$func_to_host_path_tmp1" "$func_to_host_path_result" | |
1873 | func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" | |
1874 | fi | |
1875 | } | |
1876 | # end func_convert_path_cygwin_to_w32 | |
1877 | ||
1878 | ||
1879 | # func_convert_path_nix_to_w32 ARG | |
1880 | # Convert path ARG from *nix to w32 format. Requires a wine environment and | |
1881 | # a working winepath. Returns result in func_to_host_file_result. | |
1882 | func_convert_path_nix_to_w32 () | |
1883 | { | |
1884 | $opt_debug | |
1885 | func_to_host_path_result="$1" | |
1886 | if test -n "$1"; then | |
1887 | # See func_convert_path_msys_to_w32: | |
1888 | func_stripname : : "$1" | |
1889 | func_to_host_path_tmp1=$func_stripname_result | |
1890 | func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" | |
1891 | func_to_host_path_result="$func_convert_core_path_wine_to_w32_result" | |
1892 | func_convert_path_check : ";" \ | |
1893 | "$func_to_host_path_tmp1" "$func_to_host_path_result" | |
1894 | func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" | |
1895 | fi | |
1896 | } | |
1897 | # end func_convert_path_nix_to_w32 | |
1898 | ||
1899 | ||
1900 | # func_convert_path_msys_to_cygwin ARG | |
1901 | # Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. | |
1902 | # Returns result in func_to_host_file_result. | |
1903 | func_convert_path_msys_to_cygwin () | |
1904 | { | |
1905 | $opt_debug | |
1906 | func_to_host_path_result="$1" | |
1907 | if test -n "$1"; then | |
1908 | # See func_convert_path_msys_to_w32: | |
1909 | func_stripname : : "$1" | |
1910 | func_to_host_path_tmp1=$func_stripname_result | |
1911 | func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" | |
1912 | func_cygpath -u -p "$func_convert_core_msys_to_w32_result" | |
1913 | func_to_host_path_result="$func_cygpath_result" | |
1914 | func_convert_path_check : : \ | |
1915 | "$func_to_host_path_tmp1" "$func_to_host_path_result" | |
1916 | func_convert_path_front_back_pathsep ":*" "*:" : "$1" | |
1917 | fi | |
1918 | } | |
1919 | # end func_convert_path_msys_to_cygwin | |
1920 | ||
1921 | ||
1922 | # func_convert_path_nix_to_cygwin ARG | |
1923 | # Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a | |
1924 | # a wine environment, working winepath, and LT_CYGPATH set. Returns result in | |
1925 | # func_to_host_file_result. | |
1926 | func_convert_path_nix_to_cygwin () | |
1927 | { | |
1928 | $opt_debug | |
1929 | func_to_host_path_result="$1" | |
1930 | if test -n "$1"; then | |
1931 | # Remove leading and trailing path separator characters from | |
1932 | # ARG. msys behavior is inconsistent here, cygpath turns them | |
1933 | # into '.;' and ';.', and winepath ignores them completely. | |
1934 | func_stripname : : "$1" | |
1935 | func_to_host_path_tmp1=$func_stripname_result | |
1936 | func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" | |
1937 | func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" | |
1938 | func_to_host_path_result="$func_cygpath_result" | |
1939 | func_convert_path_check : : \ | |
1940 | "$func_to_host_path_tmp1" "$func_to_host_path_result" | |
1941 | func_convert_path_front_back_pathsep ":*" "*:" : "$1" | |
1942 | fi | |
1943 | } | |
1944 | # end func_convert_path_nix_to_cygwin | |
1945 | ||
1946 | ||
1265 | 1947 | # func_mode_compile arg... |
1266 | 1948 | func_mode_compile () |
1267 | 1949 | { |
1302 | 1984 | ;; |
1303 | 1985 | |
1304 | 1986 | -pie | -fpie | -fPIE) |
1305 | pie_flag="$pie_flag $arg" | |
1987 | func_append pie_flag " $arg" | |
1306 | 1988 | continue |
1307 | 1989 | ;; |
1308 | 1990 | |
1309 | 1991 | -shared | -static | -prefer-pic | -prefer-non-pic) |
1310 | later="$later $arg" | |
1992 | func_append later " $arg" | |
1311 | 1993 | continue |
1312 | 1994 | ;; |
1313 | 1995 | |
1328 | 2010 | save_ifs="$IFS"; IFS=',' |
1329 | 2011 | for arg in $args; do |
1330 | 2012 | IFS="$save_ifs" |
1331 | func_quote_for_eval "$arg" | |
1332 | lastarg="$lastarg $func_quote_for_eval_result" | |
2013 | func_append_quoted lastarg "$arg" | |
1333 | 2014 | done |
1334 | 2015 | IFS="$save_ifs" |
1335 | 2016 | func_stripname ' ' '' "$lastarg" |
1336 | 2017 | lastarg=$func_stripname_result |
1337 | 2018 | |
1338 | 2019 | # Add the arguments to base_compile. |
1339 | base_compile="$base_compile $lastarg" | |
2020 | func_append base_compile " $lastarg" | |
1340 | 2021 | continue |
1341 | 2022 | ;; |
1342 | 2023 | |
1352 | 2033 | esac # case $arg_mode |
1353 | 2034 | |
1354 | 2035 | # Aesthetically quote the previous argument. |
1355 | func_quote_for_eval "$lastarg" | |
1356 | base_compile="$base_compile $func_quote_for_eval_result" | |
2036 | func_append_quoted base_compile "$lastarg" | |
1357 | 2037 | done # for arg |
1358 | 2038 | |
1359 | 2039 | case $arg_mode in |
1484 | 2164 | $opt_dry_run || $RM $removelist |
1485 | 2165 | exit $EXIT_FAILURE |
1486 | 2166 | fi |
1487 | removelist="$removelist $output_obj" | |
2167 | func_append removelist " $output_obj" | |
1488 | 2168 | $ECHO "$srcfile" > "$lockfile" |
1489 | 2169 | fi |
1490 | 2170 | |
1491 | 2171 | $opt_dry_run || $RM $removelist |
1492 | removelist="$removelist $lockfile" | |
2172 | func_append removelist " $lockfile" | |
1493 | 2173 | trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 |
1494 | 2174 | |
1495 | if test -n "$fix_srcfile_path"; then | |
1496 | eval srcfile=\"$fix_srcfile_path\" | |
1497 | fi | |
2175 | func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 | |
2176 | srcfile=$func_to_tool_file_result | |
1498 | 2177 | func_quote_for_eval "$srcfile" |
1499 | 2178 | qsrcfile=$func_quote_for_eval_result |
1500 | 2179 | |
1514 | 2193 | |
1515 | 2194 | if test -z "$output_obj"; then |
1516 | 2195 | # Place PIC objects in $objdir |
1517 | command="$command -o $lobj" | |
2196 | func_append command " -o $lobj" | |
1518 | 2197 | fi |
1519 | 2198 | |
1520 | 2199 | func_show_eval_locale "$command" \ |
1561 | 2240 | command="$base_compile $qsrcfile $pic_flag" |
1562 | 2241 | fi |
1563 | 2242 | if test "$compiler_c_o" = yes; then |
1564 | command="$command -o $obj" | |
2243 | func_append command " -o $obj" | |
1565 | 2244 | fi |
1566 | 2245 | |
1567 | 2246 | # Suppress compiler output if we already did a PIC compilation. |
1568 | command="$command$suppress_output" | |
2247 | func_append command "$suppress_output" | |
1569 | 2248 | func_show_eval_locale "$command" \ |
1570 | 2249 | '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' |
1571 | 2250 | |
1610 | 2289 | } |
1611 | 2290 | |
1612 | 2291 | $opt_help || { |
1613 | test "$mode" = compile && func_mode_compile ${1+"$@"} | |
2292 | test "$opt_mode" = compile && func_mode_compile ${1+"$@"} | |
1614 | 2293 | } |
1615 | 2294 | |
1616 | 2295 | func_mode_help () |
1617 | 2296 | { |
1618 | 2297 | # We need to display help for each of the modes. |
1619 | case $mode in | |
2298 | case $opt_mode in | |
1620 | 2299 | "") |
1621 | 2300 | # Generic help is extracted from the usage comments |
1622 | 2301 | # at the start of this file. |
1792 | 2471 | ;; |
1793 | 2472 | |
1794 | 2473 | *) |
1795 | func_fatal_help "invalid operation mode \`$mode'" | |
2474 | func_fatal_help "invalid operation mode \`$opt_mode'" | |
1796 | 2475 | ;; |
1797 | 2476 | esac |
1798 | 2477 | |
1807 | 2486 | else |
1808 | 2487 | { |
1809 | 2488 | func_help noexit |
1810 | for mode in compile link execute install finish uninstall clean; do | |
2489 | for opt_mode in compile link execute install finish uninstall clean; do | |
1811 | 2490 | func_mode_help |
1812 | 2491 | done |
1813 | 2492 | } | sed -n '1p; 2,$s/^Usage:/ or: /p' |
1814 | 2493 | { |
1815 | 2494 | func_help noexit |
1816 | for mode in compile link execute install finish uninstall clean; do | |
2495 | for opt_mode in compile link execute install finish uninstall clean; do | |
1817 | 2496 | echo |
1818 | 2497 | func_mode_help |
1819 | 2498 | done |
1842 | 2521 | func_fatal_help "you must specify a COMMAND" |
1843 | 2522 | |
1844 | 2523 | # Handle -dlopen flags immediately. |
1845 | for file in $execute_dlfiles; do | |
2524 | for file in $opt_dlopen; do | |
1846 | 2525 | test -f "$file" \ |
1847 | 2526 | || func_fatal_help "\`$file' is not a file" |
1848 | 2527 | |
1849 | 2528 | dir= |
1850 | 2529 | case $file in |
1851 | 2530 | *.la) |
2531 | func_resolve_sysroot "$file" | |
2532 | file=$func_resolve_sysroot_result | |
2533 | ||
1852 | 2534 | # Check to see that this really is a libtool archive. |
1853 | 2535 | func_lalib_unsafe_p "$file" \ |
1854 | 2536 | || func_fatal_help "\`$lib' is not a valid libtool archive" |
1870 | 2552 | dir="$func_dirname_result" |
1871 | 2553 | |
1872 | 2554 | if test -f "$dir/$objdir/$dlname"; then |
1873 | dir="$dir/$objdir" | |
2555 | func_append dir "/$objdir" | |
1874 | 2556 | else |
1875 | 2557 | if test ! -f "$dir/$dlname"; then |
1876 | 2558 | func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" |
1927 | 2609 | ;; |
1928 | 2610 | esac |
1929 | 2611 | # Quote arguments (to preserve shell metacharacters). |
1930 | func_quote_for_eval "$file" | |
1931 | args="$args $func_quote_for_eval_result" | |
2612 | func_append_quoted args "$file" | |
1932 | 2613 | done |
1933 | 2614 | |
1934 | 2615 | if test "X$opt_dry_run" = Xfalse; then |
1960 | 2641 | fi |
1961 | 2642 | } |
1962 | 2643 | |
1963 | test "$mode" = execute && func_mode_execute ${1+"$@"} | |
2644 | test "$opt_mode" = execute && func_mode_execute ${1+"$@"} | |
1964 | 2645 | |
1965 | 2646 | |
1966 | 2647 | # func_mode_finish arg... |
1967 | 2648 | func_mode_finish () |
1968 | 2649 | { |
1969 | 2650 | $opt_debug |
1970 | libdirs="$nonopt" | |
2651 | libs= | |
2652 | libdirs= | |
1971 | 2653 | admincmds= |
1972 | 2654 | |
2655 | for opt in "$nonopt" ${1+"$@"} | |
2656 | do | |
2657 | if test -d "$opt"; then | |
2658 | func_append libdirs " $opt" | |
2659 | ||
2660 | elif test -f "$opt"; then | |
2661 | if func_lalib_unsafe_p "$opt"; then | |
2662 | func_append libs " $opt" | |
2663 | else | |
2664 | func_warning "\`$opt' is not a valid libtool archive" | |
2665 | fi | |
2666 | ||
2667 | else | |
2668 | func_fatal_error "invalid argument \`$opt'" | |
2669 | fi | |
2670 | done | |
2671 | ||
2672 | if test -n "$libs"; then | |
2673 | if test -n "$lt_sysroot"; then | |
2674 | sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` | |
2675 | sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" | |
2676 | else | |
2677 | sysroot_cmd= | |
2678 | fi | |
2679 | ||
2680 | # Remove sysroot references | |
2681 | if $opt_dry_run; then | |
2682 | for lib in $libs; do | |
2683 | echo "removing references to $lt_sysroot and \`=' prefixes from $lib" | |
2684 | done | |
2685 | else | |
2686 | tmpdir=`func_mktempdir` | |
2687 | for lib in $libs; do | |
2688 | sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ | |
2689 | > $tmpdir/tmp-la | |
2690 | mv -f $tmpdir/tmp-la $lib | |
2691 | done | |
2692 | ${RM}r "$tmpdir" | |
2693 | fi | |
2694 | fi | |
2695 | ||
1973 | 2696 | if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then |
1974 | for dir | |
1975 | do | |
1976 | libdirs="$libdirs $dir" | |
1977 | done | |
1978 | ||
1979 | 2697 | for libdir in $libdirs; do |
1980 | 2698 | if test -n "$finish_cmds"; then |
1981 | 2699 | # Do each command in the finish commands. |
1985 | 2703 | if test -n "$finish_eval"; then |
1986 | 2704 | # Do the single finish_eval. |
1987 | 2705 | eval cmds=\"$finish_eval\" |
1988 | $opt_dry_run || eval "$cmds" || admincmds="$admincmds | |
2706 | $opt_dry_run || eval "$cmds" || func_append admincmds " | |
1989 | 2707 | $cmds" |
1990 | 2708 | fi |
1991 | 2709 | done |
1994 | 2712 | # Exit here if they wanted silent mode. |
1995 | 2713 | $opt_silent && exit $EXIT_SUCCESS |
1996 | 2714 | |
1997 | echo "----------------------------------------------------------------------" | |
1998 | echo "Libraries have been installed in:" | |
1999 | for libdir in $libdirs; do | |
2000 | $ECHO " $libdir" | |
2001 | done | |
2002 | echo | |
2003 | echo "If you ever happen to want to link against installed libraries" | |
2004 | echo "in a given directory, LIBDIR, you must either use libtool, and" | |
2005 | echo "specify the full pathname of the library, or use the \`-LLIBDIR'" | |
2006 | echo "flag during linking and do at least one of the following:" | |
2007 | if test -n "$shlibpath_var"; then | |
2008 | echo " - add LIBDIR to the \`$shlibpath_var' environment variable" | |
2009 | echo " during execution" | |
2715 | if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then | |
2716 | echo "----------------------------------------------------------------------" | |
2717 | echo "Libraries have been installed in:" | |
2718 | for libdir in $libdirs; do | |
2719 | $ECHO " $libdir" | |
2720 | done | |
2721 | echo | |
2722 | echo "If you ever happen to want to link against installed libraries" | |
2723 | echo "in a given directory, LIBDIR, you must either use libtool, and" | |
2724 | echo "specify the full pathname of the library, or use the \`-LLIBDIR'" | |
2725 | echo "flag during linking and do at least one of the following:" | |
2726 | if test -n "$shlibpath_var"; then | |
2727 | echo " - add LIBDIR to the \`$shlibpath_var' environment variable" | |
2728 | echo " during execution" | |
2729 | fi | |
2730 | if test -n "$runpath_var"; then | |
2731 | echo " - add LIBDIR to the \`$runpath_var' environment variable" | |
2732 | echo " during linking" | |
2733 | fi | |
2734 | if test -n "$hardcode_libdir_flag_spec"; then | |
2735 | libdir=LIBDIR | |
2736 | eval flag=\"$hardcode_libdir_flag_spec\" | |
2737 | ||
2738 | $ECHO " - use the \`$flag' linker flag" | |
2739 | fi | |
2740 | if test -n "$admincmds"; then | |
2741 | $ECHO " - have your system administrator run these commands:$admincmds" | |
2742 | fi | |
2743 | if test -f /etc/ld.so.conf; then | |
2744 | echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" | |
2745 | fi | |
2746 | echo | |
2747 | ||
2748 | echo "See any operating system documentation about shared libraries for" | |
2749 | case $host in | |
2750 | solaris2.[6789]|solaris2.1[0-9]) | |
2751 | echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" | |
2752 | echo "pages." | |
2753 | ;; | |
2754 | *) | |
2755 | echo "more information, such as the ld(1) and ld.so(8) manual pages." | |
2756 | ;; | |
2757 | esac | |
2758 | echo "----------------------------------------------------------------------" | |
2010 | 2759 | fi |
2011 | if test -n "$runpath_var"; then | |
2012 | echo " - add LIBDIR to the \`$runpath_var' environment variable" | |
2013 | echo " during linking" | |
2014 | fi | |
2015 | if test -n "$hardcode_libdir_flag_spec"; then | |
2016 | libdir=LIBDIR | |
2017 | eval flag=\"$hardcode_libdir_flag_spec\" | |
2018 | ||
2019 | $ECHO " - use the \`$flag' linker flag" | |
2020 | fi | |
2021 | if test -n "$admincmds"; then | |
2022 | $ECHO " - have your system administrator run these commands:$admincmds" | |
2023 | fi | |
2024 | if test -f /etc/ld.so.conf; then | |
2025 | echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" | |
2026 | fi | |
2027 | echo | |
2028 | ||
2029 | echo "See any operating system documentation about shared libraries for" | |
2030 | case $host in | |
2031 | solaris2.[6789]|solaris2.1[0-9]) | |
2032 | echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" | |
2033 | echo "pages." | |
2034 | ;; | |
2035 | *) | |
2036 | echo "more information, such as the ld(1) and ld.so(8) manual pages." | |
2037 | ;; | |
2038 | esac | |
2039 | echo "----------------------------------------------------------------------" | |
2040 | 2760 | exit $EXIT_SUCCESS |
2041 | 2761 | } |
2042 | 2762 | |
2043 | test "$mode" = finish && func_mode_finish ${1+"$@"} | |
2763 | test "$opt_mode" = finish && func_mode_finish ${1+"$@"} | |
2044 | 2764 | |
2045 | 2765 | |
2046 | 2766 | # func_mode_install arg... |
2065 | 2785 | # The real first argument should be the name of the installation program. |
2066 | 2786 | # Aesthetically quote it. |
2067 | 2787 | func_quote_for_eval "$arg" |
2068 | install_prog="$install_prog$func_quote_for_eval_result" | |
2788 | func_append install_prog "$func_quote_for_eval_result" | |
2069 | 2789 | install_shared_prog=$install_prog |
2070 | 2790 | case " $install_prog " in |
2071 | 2791 | *[\\\ /]cp\ *) install_cp=: ;; |
2085 | 2805 | do |
2086 | 2806 | arg2= |
2087 | 2807 | if test -n "$dest"; then |
2088 | files="$files $dest" | |
2808 | func_append files " $dest" | |
2089 | 2809 | dest=$arg |
2090 | 2810 | continue |
2091 | 2811 | fi |
2123 | 2843 | |
2124 | 2844 | # Aesthetically quote the argument. |
2125 | 2845 | func_quote_for_eval "$arg" |
2126 | install_prog="$install_prog $func_quote_for_eval_result" | |
2846 | func_append install_prog " $func_quote_for_eval_result" | |
2127 | 2847 | if test -n "$arg2"; then |
2128 | 2848 | func_quote_for_eval "$arg2" |
2129 | 2849 | fi |
2130 | install_shared_prog="$install_shared_prog $func_quote_for_eval_result" | |
2850 | func_append install_shared_prog " $func_quote_for_eval_result" | |
2131 | 2851 | done |
2132 | 2852 | |
2133 | 2853 | test -z "$install_prog" && \ |
2139 | 2859 | if test -n "$install_override_mode" && $no_mode; then |
2140 | 2860 | if $install_cp; then :; else |
2141 | 2861 | func_quote_for_eval "$install_override_mode" |
2142 | install_shared_prog="$install_shared_prog -m $func_quote_for_eval_result" | |
2862 | func_append install_shared_prog " -m $func_quote_for_eval_result" | |
2143 | 2863 | fi |
2144 | 2864 | fi |
2145 | 2865 | |
2197 | 2917 | case $file in |
2198 | 2918 | *.$libext) |
2199 | 2919 | # Do the static libraries later. |
2200 | staticlibs="$staticlibs $file" | |
2920 | func_append staticlibs " $file" | |
2201 | 2921 | ;; |
2202 | 2922 | |
2203 | 2923 | *.la) |
2924 | func_resolve_sysroot "$file" | |
2925 | file=$func_resolve_sysroot_result | |
2926 | ||
2204 | 2927 | # Check to see that this really is a libtool archive. |
2205 | 2928 | func_lalib_unsafe_p "$file" \ |
2206 | 2929 | || func_fatal_help "\`$file' is not a valid libtool archive" |
2214 | 2937 | if test "X$destdir" = "X$libdir"; then |
2215 | 2938 | case "$current_libdirs " in |
2216 | 2939 | *" $libdir "*) ;; |
2217 | *) current_libdirs="$current_libdirs $libdir" ;; | |
2940 | *) func_append current_libdirs " $libdir" ;; | |
2218 | 2941 | esac |
2219 | 2942 | else |
2220 | 2943 | # Note the libdir as a future libdir. |
2221 | 2944 | case "$future_libdirs " in |
2222 | 2945 | *" $libdir "*) ;; |
2223 | *) future_libdirs="$future_libdirs $libdir" ;; | |
2946 | *) func_append future_libdirs " $libdir" ;; | |
2224 | 2947 | esac |
2225 | 2948 | fi |
2226 | 2949 | |
2227 | 2950 | func_dirname "$file" "/" "" |
2228 | 2951 | dir="$func_dirname_result" |
2229 | dir="$dir$objdir" | |
2952 | func_append dir "$objdir" | |
2230 | 2953 | |
2231 | 2954 | if test -n "$relink_command"; then |
2232 | 2955 | # Determine the prefix the user has applied to our future dir. |
2303 | 3026 | func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' |
2304 | 3027 | |
2305 | 3028 | # Maybe install the static library, too. |
2306 | test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" | |
3029 | test -n "$old_library" && func_append staticlibs " $dir/$old_library" | |
2307 | 3030 | ;; |
2308 | 3031 | |
2309 | 3032 | *.lo) |
2500 | 3223 | fi |
2501 | 3224 | } |
2502 | 3225 | |
2503 | test "$mode" = install && func_mode_install ${1+"$@"} | |
3226 | test "$opt_mode" = install && func_mode_install ${1+"$@"} | |
2504 | 3227 | |
2505 | 3228 | |
2506 | 3229 | # func_generate_dlsyms outputname originator pic_p |
2547 | 3270 | #pragma GCC diagnostic ignored \"-Wstrict-prototypes\" |
2548 | 3271 | #endif |
2549 | 3272 | |
3273 | /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ | |
3274 | #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) | |
3275 | /* DATA imports from DLLs on WIN32 con't be const, because runtime | |
3276 | relocations are performed -- see ld's documentation on pseudo-relocs. */ | |
3277 | # define LT_DLSYM_CONST | |
3278 | #elif defined(__osf__) | |
3279 | /* This system does not cope well with relocations in const data. */ | |
3280 | # define LT_DLSYM_CONST | |
3281 | #else | |
3282 | # define LT_DLSYM_CONST const | |
3283 | #endif | |
3284 | ||
2550 | 3285 | /* External symbol declarations for the compiler. */\ |
2551 | 3286 | " |
2552 | 3287 | |
2558 | 3293 | # Add our own program objects to the symbol list. |
2559 | 3294 | progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` |
2560 | 3295 | for progfile in $progfiles; do |
2561 | func_verbose "extracting global C symbols from \`$progfile'" | |
2562 | $opt_dry_run || eval "$NM $progfile | $global_symbol_pipe >> '$nlist'" | |
3296 | func_to_tool_file "$progfile" func_convert_file_msys_to_w32 | |
3297 | func_verbose "extracting global C symbols from \`$func_to_tool_file_result'" | |
3298 | $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" | |
2563 | 3299 | done |
2564 | 3300 | |
2565 | 3301 | if test -n "$exclude_expsyms"; then |
2608 | 3344 | func_verbose "extracting global C symbols from \`$dlprefile'" |
2609 | 3345 | func_basename "$dlprefile" |
2610 | 3346 | name="$func_basename_result" |
2611 | $opt_dry_run || { | |
2612 | eval '$ECHO ": $name " >> "$nlist"' | |
2613 | eval "$NM $dlprefile 2>/dev/null | $global_symbol_pipe >> '$nlist'" | |
2614 | } | |
3347 | case $host in | |
3348 | *cygwin* | *mingw* | *cegcc* ) | |
3349 | # if an import library, we need to obtain dlname | |
3350 | if func_win32_import_lib_p "$dlprefile"; then | |
3351 | func_tr_sh "$dlprefile" | |
3352 | eval "curr_lafile=\$libfile_$func_tr_sh_result" | |
3353 | dlprefile_dlbasename="" | |
3354 | if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then | |
3355 | # Use subshell, to avoid clobbering current variable values | |
3356 | dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` | |
3357 | if test -n "$dlprefile_dlname" ; then | |
3358 | func_basename "$dlprefile_dlname" | |
3359 | dlprefile_dlbasename="$func_basename_result" | |
3360 | else | |
3361 | # no lafile. user explicitly requested -dlpreopen <import library>. | |
3362 | $sharedlib_from_linklib_cmd "$dlprefile" | |
3363 | dlprefile_dlbasename=$sharedlib_from_linklib_result | |
3364 | fi | |
3365 | fi | |
3366 | $opt_dry_run || { | |
3367 | if test -n "$dlprefile_dlbasename" ; then | |
3368 | eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' | |
3369 | else | |
3370 | func_warning "Could not compute DLL name from $name" | |
3371 | eval '$ECHO ": $name " >> "$nlist"' | |
3372 | fi | |
3373 | func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 | |
3374 | eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | | |
3375 | $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" | |
3376 | } | |
3377 | else # not an import lib | |
3378 | $opt_dry_run || { | |
3379 | eval '$ECHO ": $name " >> "$nlist"' | |
3380 | func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 | |
3381 | eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" | |
3382 | } | |
3383 | fi | |
3384 | ;; | |
3385 | *) | |
3386 | $opt_dry_run || { | |
3387 | eval '$ECHO ": $name " >> "$nlist"' | |
3388 | func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 | |
3389 | eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" | |
3390 | } | |
3391 | ;; | |
3392 | esac | |
2615 | 3393 | done |
2616 | 3394 | |
2617 | 3395 | $opt_dry_run || { |
2649 | 3427 | const char *name; |
2650 | 3428 | void *address; |
2651 | 3429 | } lt_dlsymlist; |
2652 | " | |
2653 | case $host in | |
2654 | *cygwin* | *mingw* | *cegcc* ) | |
2655 | echo >> "$output_objdir/$my_dlsyms" "\ | |
2656 | /* DATA imports from DLLs on WIN32 con't be const, because | |
2657 | runtime relocations are performed -- see ld's documentation | |
2658 | on pseudo-relocs. */" | |
2659 | lt_dlsym_const= ;; | |
2660 | *osf5*) | |
2661 | echo >> "$output_objdir/$my_dlsyms" "\ | |
2662 | /* This system does not cope well with relocations in const data */" | |
2663 | lt_dlsym_const= ;; | |
2664 | *) | |
2665 | lt_dlsym_const=const ;; | |
2666 | esac | |
2667 | ||
2668 | echo >> "$output_objdir/$my_dlsyms" "\ | |
2669 | extern $lt_dlsym_const lt_dlsymlist | |
3430 | extern LT_DLSYM_CONST lt_dlsymlist | |
2670 | 3431 | lt_${my_prefix}_LTX_preloaded_symbols[]; |
2671 | $lt_dlsym_const lt_dlsymlist | |
3432 | LT_DLSYM_CONST lt_dlsymlist | |
2672 | 3433 | lt_${my_prefix}_LTX_preloaded_symbols[] = |
2673 | 3434 | {\ |
2674 | 3435 | { \"$my_originator\", (void *) 0 }," |
2724 | 3485 | for arg in $LTCFLAGS; do |
2725 | 3486 | case $arg in |
2726 | 3487 | -pie | -fpie | -fPIE) ;; |
2727 | *) symtab_cflags="$symtab_cflags $arg" ;; | |
3488 | *) func_append symtab_cflags " $arg" ;; | |
2728 | 3489 | esac |
2729 | 3490 | done |
2730 | 3491 | |
2787 | 3548 | # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. |
2788 | 3549 | if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | |
2789 | 3550 | $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then |
2790 | win32_nmres=`eval $NM -f posix -A $1 | | |
3551 | func_to_tool_file "$1" func_convert_file_msys_to_w32 | |
3552 | win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | | |
2791 | 3553 | $SED -n -e ' |
2792 | 3554 | 1,100{ |
2793 | 3555 | / I /{ |
2816 | 3578 | $ECHO "$win32_libid_type" |
2817 | 3579 | } |
2818 | 3580 | |
3581 | # func_cygming_dll_for_implib ARG | |
3582 | # | |
3583 | # Platform-specific function to extract the | |
3584 | # name of the DLL associated with the specified | |
3585 | # import library ARG. | |
3586 | # Invoked by eval'ing the libtool variable | |
3587 | # $sharedlib_from_linklib_cmd | |
3588 | # Result is available in the variable | |
3589 | # $sharedlib_from_linklib_result | |
3590 | func_cygming_dll_for_implib () | |
3591 | { | |
3592 | $opt_debug | |
3593 | sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` | |
3594 | } | |
3595 | ||
3596 | # func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs | |
3597 | # | |
3598 | # The is the core of a fallback implementation of a | |
3599 | # platform-specific function to extract the name of the | |
3600 | # DLL associated with the specified import library LIBNAME. | |
3601 | # | |
3602 | # SECTION_NAME is either .idata$6 or .idata$7, depending | |
3603 | # on the platform and compiler that created the implib. | |
3604 | # | |
3605 | # Echos the name of the DLL associated with the | |
3606 | # specified import library. | |
3607 | func_cygming_dll_for_implib_fallback_core () | |
3608 | { | |
3609 | $opt_debug | |
3610 | match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` | |
3611 | $OBJDUMP -s --section "$1" "$2" 2>/dev/null | | |
3612 | $SED '/^Contents of section '"$match_literal"':/{ | |
3613 | # Place marker at beginning of archive member dllname section | |
3614 | s/.*/====MARK====/ | |
3615 | p | |
3616 | d | |
3617 | } | |
3618 | # These lines can sometimes be longer than 43 characters, but | |
3619 | # are always uninteresting | |
3620 | /:[ ]*file format pe[i]\{,1\}-/d | |
3621 | /^In archive [^:]*:/d | |
3622 | # Ensure marker is printed | |
3623 | /^====MARK====/p | |
3624 | # Remove all lines with less than 43 characters | |
3625 | /^.\{43\}/!d | |
3626 | # From remaining lines, remove first 43 characters | |
3627 | s/^.\{43\}//' | | |
3628 | $SED -n ' | |
3629 | # Join marker and all lines until next marker into a single line | |
3630 | /^====MARK====/ b para | |
3631 | H | |
3632 | $ b para | |
3633 | b | |
3634 | :para | |
3635 | x | |
3636 | s/\n//g | |
3637 | # Remove the marker | |
3638 | s/^====MARK====// | |
3639 | # Remove trailing dots and whitespace | |
3640 | s/[\. \t]*$// | |
3641 | ||
3642 | /./p' | | |
3643 | # we now have a list, one entry per line, of the stringified | |
3644 | # contents of the appropriate section of all members of the | |
3645 | # archive which possess that section. Heuristic: eliminate | |
3646 | # all those which have a first or second character that is | |
3647 | # a '.' (that is, objdump's representation of an unprintable | |
3648 | # character.) This should work for all archives with less than | |
3649 | # 0x302f exports -- but will fail for DLLs whose name actually | |
3650 | # begins with a literal '.' or a single character followed by | |
3651 | # a '.'. | |
3652 | # | |
3653 | # Of those that remain, print the first one. | |
3654 | $SED -e '/^\./d;/^.\./d;q' | |
3655 | } | |
3656 | ||
3657 | # func_cygming_gnu_implib_p ARG | |
3658 | # This predicate returns with zero status (TRUE) if | |
3659 | # ARG is a GNU/binutils-style import library. Returns | |
3660 | # with nonzero status (FALSE) otherwise. | |
3661 | func_cygming_gnu_implib_p () | |
3662 | { | |
3663 | $opt_debug | |
3664 | func_to_tool_file "$1" func_convert_file_msys_to_w32 | |
3665 | func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'` | |
3666 | test -n "$func_cygming_gnu_implib_tmp" | |
3667 | } | |
3668 | ||
3669 | # func_cygming_ms_implib_p ARG | |
3670 | # This predicate returns with zero status (TRUE) if | |
3671 | # ARG is an MS-style import library. Returns | |
3672 | # with nonzero status (FALSE) otherwise. | |
3673 | func_cygming_ms_implib_p () | |
3674 | { | |
3675 | $opt_debug | |
3676 | func_to_tool_file "$1" func_convert_file_msys_to_w32 | |
3677 | func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` | |
3678 | test -n "$func_cygming_ms_implib_tmp" | |
3679 | } | |
3680 | ||
3681 | # func_cygming_dll_for_implib_fallback ARG | |
3682 | # Platform-specific function to extract the | |
3683 | # name of the DLL associated with the specified | |
3684 | # import library ARG. | |
3685 | # | |
3686 | # This fallback implementation is for use when $DLLTOOL | |
3687 | # does not support the --identify-strict option. | |
3688 | # Invoked by eval'ing the libtool variable | |
3689 | # $sharedlib_from_linklib_cmd | |
3690 | # Result is available in the variable | |
3691 | # $sharedlib_from_linklib_result | |
3692 | func_cygming_dll_for_implib_fallback () | |
3693 | { | |
3694 | $opt_debug | |
3695 | if func_cygming_gnu_implib_p "$1" ; then | |
3696 | # binutils import library | |
3697 | sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` | |
3698 | elif func_cygming_ms_implib_p "$1" ; then | |
3699 | # ms-generated import library | |
3700 | sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` | |
3701 | else | |
3702 | # unknown | |
3703 | sharedlib_from_linklib_result="" | |
3704 | fi | |
3705 | } | |
2819 | 3706 | |
2820 | 3707 | |
2821 | 3708 | # func_extract_an_archive dir oldlib |
3194 | 4081 | |
3195 | 4082 | if test -f \"\$progdir/\$program\"; then" |
3196 | 4083 | |
4084 | # fixup the dll searchpath if we need to. | |
4085 | # | |
4086 | # Fix the DLL searchpath if we need to. Do this before prepending | |
4087 | # to shlibpath, because on Windows, both are PATH and uninstalled | |
4088 | # libraries must come first. | |
4089 | if test -n "$dllsearchpath"; then | |
4090 | $ECHO "\ | |
4091 | # Add the dll search path components to the executable PATH | |
4092 | PATH=$dllsearchpath:\$PATH | |
4093 | " | |
4094 | fi | |
4095 | ||
3197 | 4096 | # Export our shlibpath_var if we have one. |
3198 | 4097 | if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then |
3199 | 4098 | $ECHO "\ |
3205 | 4104 | $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` |
3206 | 4105 | |
3207 | 4106 | export $shlibpath_var |
3208 | " | |
3209 | fi | |
3210 | ||
3211 | # fixup the dll searchpath if we need to. | |
3212 | if test -n "$dllsearchpath"; then | |
3213 | $ECHO "\ | |
3214 | # Add the dll search path components to the executable PATH | |
3215 | PATH=$dllsearchpath:\$PATH | |
3216 | 4107 | " |
3217 | 4108 | fi |
3218 | 4109 | |
3232 | 4123 | " |
3233 | 4124 | } |
3234 | 4125 | |
3235 | ||
3236 | # func_to_host_path arg | |
3237 | # | |
3238 | # Convert paths to host format when used with build tools. | |
3239 | # Intended for use with "native" mingw (where libtool itself | |
3240 | # is running under the msys shell), or in the following cross- | |
3241 | # build environments: | |
3242 | # $build $host | |
3243 | # mingw (msys) mingw [e.g. native] | |
3244 | # cygwin mingw | |
3245 | # *nix + wine mingw | |
3246 | # where wine is equipped with the `winepath' executable. | |
3247 | # In the native mingw case, the (msys) shell automatically | |
3248 | # converts paths for any non-msys applications it launches, | |
3249 | # but that facility isn't available from inside the cwrapper. | |
3250 | # Similar accommodations are necessary for $host mingw and | |
3251 | # $build cygwin. Calling this function does no harm for other | |
3252 | # $host/$build combinations not listed above. | |
3253 | # | |
3254 | # ARG is the path (on $build) that should be converted to | |
3255 | # the proper representation for $host. The result is stored | |
3256 | # in $func_to_host_path_result. | |
3257 | func_to_host_path () | |
3258 | { | |
3259 | func_to_host_path_result="$1" | |
3260 | if test -n "$1"; then | |
3261 | case $host in | |
3262 | *mingw* ) | |
3263 | lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' | |
3264 | case $build in | |
3265 | *mingw* ) # actually, msys | |
3266 | # awkward: cmd appends spaces to result | |
3267 | func_to_host_path_result=`( cmd //c echo "$1" ) 2>/dev/null | | |
3268 | $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"` | |
3269 | ;; | |
3270 | *cygwin* ) | |
3271 | func_to_host_path_result=`cygpath -w "$1" | | |
3272 | $SED -e "$lt_sed_naive_backslashify"` | |
3273 | ;; | |
3274 | * ) | |
3275 | # Unfortunately, winepath does not exit with a non-zero | |
3276 | # error code, so we are forced to check the contents of | |
3277 | # stdout. On the other hand, if the command is not | |
3278 | # found, the shell will set an exit code of 127 and print | |
3279 | # *an error message* to stdout. So we must check for both | |
3280 | # error code of zero AND non-empty stdout, which explains | |
3281 | # the odd construction: | |
3282 | func_to_host_path_tmp1=`winepath -w "$1" 2>/dev/null` | |
3283 | if test "$?" -eq 0 && test -n "${func_to_host_path_tmp1}"; then | |
3284 | func_to_host_path_result=`$ECHO "$func_to_host_path_tmp1" | | |
3285 | $SED -e "$lt_sed_naive_backslashify"` | |
3286 | else | |
3287 | # Allow warning below. | |
3288 | func_to_host_path_result= | |
3289 | fi | |
3290 | ;; | |
3291 | esac | |
3292 | if test -z "$func_to_host_path_result" ; then | |
3293 | func_error "Could not determine host path corresponding to" | |
3294 | func_error " \`$1'" | |
3295 | func_error "Continuing, but uninstalled executables may not work." | |
3296 | # Fallback: | |
3297 | func_to_host_path_result="$1" | |
3298 | fi | |
3299 | ;; | |
3300 | esac | |
3301 | fi | |
3302 | } | |
3303 | # end: func_to_host_path | |
3304 | ||
3305 | # func_to_host_pathlist arg | |
3306 | # | |
3307 | # Convert pathlists to host format when used with build tools. | |
3308 | # See func_to_host_path(), above. This function supports the | |
3309 | # following $build/$host combinations (but does no harm for | |
3310 | # combinations not listed here): | |
3311 | # $build $host | |
3312 | # mingw (msys) mingw [e.g. native] | |
3313 | # cygwin mingw | |
3314 | # *nix + wine mingw | |
3315 | # | |
3316 | # Path separators are also converted from $build format to | |
3317 | # $host format. If ARG begins or ends with a path separator | |
3318 | # character, it is preserved (but converted to $host format) | |
3319 | # on output. | |
3320 | # | |
3321 | # ARG is a pathlist (on $build) that should be converted to | |
3322 | # the proper representation on $host. The result is stored | |
3323 | # in $func_to_host_pathlist_result. | |
3324 | func_to_host_pathlist () | |
3325 | { | |
3326 | func_to_host_pathlist_result="$1" | |
3327 | if test -n "$1"; then | |
3328 | case $host in | |
3329 | *mingw* ) | |
3330 | lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' | |
3331 | # Remove leading and trailing path separator characters from | |
3332 | # ARG. msys behavior is inconsistent here, cygpath turns them | |
3333 | # into '.;' and ';.', and winepath ignores them completely. | |
3334 | func_stripname : : "$1" | |
3335 | func_to_host_pathlist_tmp1=$func_stripname_result | |
3336 | case $build in | |
3337 | *mingw* ) # Actually, msys. | |
3338 | # Awkward: cmd appends spaces to result. | |
3339 | func_to_host_pathlist_result=` | |
3340 | ( cmd //c echo "$func_to_host_pathlist_tmp1" ) 2>/dev/null | | |
3341 | $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"` | |
3342 | ;; | |
3343 | *cygwin* ) | |
3344 | func_to_host_pathlist_result=`cygpath -w -p "$func_to_host_pathlist_tmp1" | | |
3345 | $SED -e "$lt_sed_naive_backslashify"` | |
3346 | ;; | |
3347 | * ) | |
3348 | # unfortunately, winepath doesn't convert pathlists | |
3349 | func_to_host_pathlist_result="" | |
3350 | func_to_host_pathlist_oldIFS=$IFS | |
3351 | IFS=: | |
3352 | for func_to_host_pathlist_f in $func_to_host_pathlist_tmp1 ; do | |
3353 | IFS=$func_to_host_pathlist_oldIFS | |
3354 | if test -n "$func_to_host_pathlist_f" ; then | |
3355 | func_to_host_path "$func_to_host_pathlist_f" | |
3356 | if test -n "$func_to_host_path_result" ; then | |
3357 | if test -z "$func_to_host_pathlist_result" ; then | |
3358 | func_to_host_pathlist_result="$func_to_host_path_result" | |
3359 | else | |
3360 | func_append func_to_host_pathlist_result ";$func_to_host_path_result" | |
3361 | fi | |
3362 | fi | |
3363 | fi | |
3364 | done | |
3365 | IFS=$func_to_host_pathlist_oldIFS | |
3366 | ;; | |
3367 | esac | |
3368 | if test -z "$func_to_host_pathlist_result"; then | |
3369 | func_error "Could not determine the host path(s) corresponding to" | |
3370 | func_error " \`$1'" | |
3371 | func_error "Continuing, but uninstalled executables may not work." | |
3372 | # Fallback. This may break if $1 contains DOS-style drive | |
3373 | # specifications. The fix is not to complicate the expression | |
3374 | # below, but for the user to provide a working wine installation | |
3375 | # with winepath so that path translation in the cross-to-mingw | |
3376 | # case works properly. | |
3377 | lt_replace_pathsep_nix_to_dos="s|:|;|g" | |
3378 | func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp1" |\ | |
3379 | $SED -e "$lt_replace_pathsep_nix_to_dos"` | |
3380 | fi | |
3381 | # Now, add the leading and trailing path separators back | |
3382 | case "$1" in | |
3383 | :* ) func_to_host_pathlist_result=";$func_to_host_pathlist_result" | |
3384 | ;; | |
3385 | esac | |
3386 | case "$1" in | |
3387 | *: ) func_append func_to_host_pathlist_result ";" | |
3388 | ;; | |
3389 | esac | |
3390 | ;; | |
3391 | esac | |
3392 | fi | |
3393 | } | |
3394 | # end: func_to_host_pathlist | |
3395 | 4126 | |
3396 | 4127 | # func_emit_cwrapperexe_src |
3397 | 4128 | # emit the source code for a wrapper executable on stdout |
3562 | 4293 | EOF |
3563 | 4294 | |
3564 | 4295 | cat <<EOF |
3565 | const char * MAGIC_EXE = "$magic_exe"; | |
4296 | volatile const char * MAGIC_EXE = "$magic_exe"; | |
3566 | 4297 | const char * LIB_PATH_VARNAME = "$shlibpath_var"; |
3567 | 4298 | EOF |
3568 | 4299 | |
3569 | 4300 | if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then |
3570 | func_to_host_pathlist "$temp_rpath" | |
4301 | func_to_host_path "$temp_rpath" | |
3571 | 4302 | cat <<EOF |
3572 | const char * LIB_PATH_VALUE = "$func_to_host_pathlist_result"; | |
4303 | const char * LIB_PATH_VALUE = "$func_to_host_path_result"; | |
3573 | 4304 | EOF |
3574 | 4305 | else |
3575 | 4306 | cat <<"EOF" |
3578 | 4309 | fi |
3579 | 4310 | |
3580 | 4311 | if test -n "$dllsearchpath"; then |
3581 | func_to_host_pathlist "$dllsearchpath:" | |
4312 | func_to_host_path "$dllsearchpath:" | |
3582 | 4313 | cat <<EOF |
3583 | 4314 | const char * EXE_PATH_VARNAME = "PATH"; |
3584 | const char * EXE_PATH_VALUE = "$func_to_host_pathlist_result"; | |
4315 | const char * EXE_PATH_VALUE = "$func_to_host_path_result"; | |
3585 | 4316 | EOF |
3586 | 4317 | else |
3587 | 4318 | cat <<"EOF" |
3764 | 4495 | |
3765 | 4496 | lt_setenv ("BIN_SH", "xpg4"); /* for Tru64 */ |
3766 | 4497 | lt_setenv ("DUALCASE", "1"); /* for MSK sh */ |
4498 | /* Update the DLL searchpath. EXE_PATH_VALUE ($dllsearchpath) must | |
4499 | be prepended before (that is, appear after) LIB_PATH_VALUE ($temp_rpath) | |
4500 | because on Windows, both *_VARNAMEs are PATH but uninstalled | |
4501 | libraries must come first. */ | |
4502 | lt_update_exe_path (EXE_PATH_VARNAME, EXE_PATH_VALUE); | |
3767 | 4503 | lt_update_lib_path (LIB_PATH_VARNAME, LIB_PATH_VALUE); |
3768 | lt_update_exe_path (EXE_PATH_VARNAME, EXE_PATH_VALUE); | |
3769 | 4504 | |
3770 | 4505 | lt_debugprintf (__FILE__, __LINE__, "(main) lt_argv_zero: %s\n", |
3771 | 4506 | nonnull (lt_argv_zero)); |
4514 | 5249 | ;; |
4515 | 5250 | *) |
4516 | 5251 | if test "$prev" = dlfiles; then |
4517 | dlfiles="$dlfiles $arg" | |
5252 | func_append dlfiles " $arg" | |
4518 | 5253 | else |
4519 | dlprefiles="$dlprefiles $arg" | |
5254 | func_append dlprefiles " $arg" | |
4520 | 5255 | fi |
4521 | 5256 | prev= |
4522 | 5257 | continue |
4540 | 5275 | *-*-darwin*) |
4541 | 5276 | case "$deplibs " in |
4542 | 5277 | *" $qarg.ltframework "*) ;; |
4543 | *) deplibs="$deplibs $qarg.ltframework" # this is fixed later | |
5278 | *) func_append deplibs " $qarg.ltframework" # this is fixed later | |
4544 | 5279 | ;; |
4545 | 5280 | esac |
4546 | 5281 | ;; |
4559 | 5294 | moreargs= |
4560 | 5295 | for fil in `cat "$save_arg"` |
4561 | 5296 | do |
4562 | # moreargs="$moreargs $fil" | |
5297 | # func_append moreargs " $fil" | |
4563 | 5298 | arg=$fil |
4564 | 5299 | # A libtool-controlled object. |
4565 | 5300 | |
4588 | 5323 | |
4589 | 5324 | if test "$prev" = dlfiles; then |
4590 | 5325 | if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then |
4591 | dlfiles="$dlfiles $pic_object" | |
5326 | func_append dlfiles " $pic_object" | |
4592 | 5327 | prev= |
4593 | 5328 | continue |
4594 | 5329 | else |
4600 | 5335 | # CHECK ME: I think I busted this. -Ossama |
4601 | 5336 | if test "$prev" = dlprefiles; then |
4602 | 5337 | # Preload the old-style object. |
4603 | dlprefiles="$dlprefiles $pic_object" | |
5338 | func_append dlprefiles " $pic_object" | |
4604 | 5339 | prev= |
4605 | 5340 | fi |
4606 | 5341 | |
4670 | 5405 | if test "$prev" = rpath; then |
4671 | 5406 | case "$rpath " in |
4672 | 5407 | *" $arg "*) ;; |
4673 | *) rpath="$rpath $arg" ;; | |
5408 | *) func_append rpath " $arg" ;; | |
4674 | 5409 | esac |
4675 | 5410 | else |
4676 | 5411 | case "$xrpath " in |
4677 | 5412 | *" $arg "*) ;; |
4678 | *) xrpath="$xrpath $arg" ;; | |
5413 | *) func_append xrpath " $arg" ;; | |
4679 | 5414 | esac |
4680 | 5415 | fi |
4681 | 5416 | prev= |
4687 | 5422 | continue |
4688 | 5423 | ;; |
4689 | 5424 | weak) |
4690 | weak_libs="$weak_libs $arg" | |
5425 | func_append weak_libs " $arg" | |
4691 | 5426 | prev= |
4692 | 5427 | continue |
4693 | 5428 | ;; |
4694 | 5429 | xcclinker) |
4695 | linker_flags="$linker_flags $qarg" | |
4696 | compiler_flags="$compiler_flags $qarg" | |
5430 | func_append linker_flags " $qarg" | |
5431 | func_append compiler_flags " $qarg" | |
4697 | 5432 | prev= |
4698 | 5433 | func_append compile_command " $qarg" |
4699 | 5434 | func_append finalize_command " $qarg" |
4700 | 5435 | continue |
4701 | 5436 | ;; |
4702 | 5437 | xcompiler) |
4703 | compiler_flags="$compiler_flags $qarg" | |
5438 | func_append compiler_flags " $qarg" | |
4704 | 5439 | prev= |
4705 | 5440 | func_append compile_command " $qarg" |
4706 | 5441 | func_append finalize_command " $qarg" |
4707 | 5442 | continue |
4708 | 5443 | ;; |
4709 | 5444 | xlinker) |
4710 | linker_flags="$linker_flags $qarg" | |
4711 | compiler_flags="$compiler_flags $wl$qarg" | |
5445 | func_append linker_flags " $qarg" | |
5446 | func_append compiler_flags " $wl$qarg" | |
4712 | 5447 | prev= |
4713 | 5448 | func_append compile_command " $wl$qarg" |
4714 | 5449 | func_append finalize_command " $wl$qarg" |
4799 | 5534 | ;; |
4800 | 5535 | |
4801 | 5536 | -L*) |
4802 | func_stripname '-L' '' "$arg" | |
4803 | dir=$func_stripname_result | |
4804 | if test -z "$dir"; then | |
5537 | func_stripname "-L" '' "$arg" | |
5538 | if test -z "$func_stripname_result"; then | |
4805 | 5539 | if test "$#" -gt 0; then |
4806 | 5540 | func_fatal_error "require no space between \`-L' and \`$1'" |
4807 | 5541 | else |
4808 | 5542 | func_fatal_error "need path for \`-L' option" |
4809 | 5543 | fi |
4810 | 5544 | fi |
5545 | func_resolve_sysroot "$func_stripname_result" | |
5546 | dir=$func_resolve_sysroot_result | |
4811 | 5547 | # We need an absolute path. |
4812 | 5548 | case $dir in |
4813 | 5549 | [\\/]* | [A-Za-z]:[\\/]*) ;; |
4819 | 5555 | ;; |
4820 | 5556 | esac |
4821 | 5557 | case "$deplibs " in |
4822 | *" -L$dir "*) ;; | |
5558 | *" -L$dir "* | *" $arg "*) | |
5559 | # Will only happen for absolute or sysroot arguments | |
5560 | ;; | |
4823 | 5561 | *) |
4824 | deplibs="$deplibs -L$dir" | |
4825 | lib_search_path="$lib_search_path $dir" | |
5562 | # Preserve sysroot, but never include relative directories | |
5563 | case $dir in | |
5564 | [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; | |
5565 | *) func_append deplibs " -L$dir" ;; | |
5566 | esac | |
5567 | func_append lib_search_path " $dir" | |
4826 | 5568 | ;; |
4827 | 5569 | esac |
4828 | 5570 | case $host in |
4831 | 5573 | case :$dllsearchpath: in |
4832 | 5574 | *":$dir:"*) ;; |
4833 | 5575 | ::) dllsearchpath=$dir;; |
4834 | *) dllsearchpath="$dllsearchpath:$dir";; | |
5576 | *) func_append dllsearchpath ":$dir";; | |
4835 | 5577 | esac |
4836 | 5578 | case :$dllsearchpath: in |
4837 | 5579 | *":$testbindir:"*) ;; |
4838 | 5580 | ::) dllsearchpath=$testbindir;; |
4839 | *) dllsearchpath="$dllsearchpath:$testbindir";; | |
5581 | *) func_append dllsearchpath ":$testbindir";; | |
4840 | 5582 | esac |
4841 | 5583 | ;; |
4842 | 5584 | esac |
4860 | 5602 | ;; |
4861 | 5603 | *-*-rhapsody* | *-*-darwin1.[012]) |
4862 | 5604 | # Rhapsody C and math libraries are in the System framework |
4863 | deplibs="$deplibs System.ltframework" | |
5605 | func_append deplibs " System.ltframework" | |
4864 | 5606 | continue |
4865 | 5607 | ;; |
4866 | 5608 | *-*-sco3.2v5* | *-*-sco5v6*) |
4880 | 5622 | ;; |
4881 | 5623 | esac |
4882 | 5624 | fi |
4883 | deplibs="$deplibs $arg" | |
5625 | func_append deplibs " $arg" | |
4884 | 5626 | continue |
4885 | 5627 | ;; |
4886 | 5628 | |
4892 | 5634 | # Tru64 UNIX uses -model [arg] to determine the layout of C++ |
4893 | 5635 | # classes, name mangling, and exception handling. |
4894 | 5636 | # Darwin uses the -arch flag to determine output architecture. |
4895 | -model|-arch|-isysroot) | |
4896 | compiler_flags="$compiler_flags $arg" | |
5637 | -model|-arch|-isysroot|--sysroot) | |
5638 | func_append compiler_flags " $arg" | |
4897 | 5639 | func_append compile_command " $arg" |
4898 | 5640 | func_append finalize_command " $arg" |
4899 | 5641 | prev=xcompiler |
4901 | 5643 | ;; |
4902 | 5644 | |
4903 | 5645 | -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) |
4904 | compiler_flags="$compiler_flags $arg" | |
5646 | func_append compiler_flags " $arg" | |
4905 | 5647 | func_append compile_command " $arg" |
4906 | 5648 | func_append finalize_command " $arg" |
4907 | 5649 | case "$new_inherited_linker_flags " in |
4908 | 5650 | *" $arg "*) ;; |
4909 | * ) new_inherited_linker_flags="$new_inherited_linker_flags $arg" ;; | |
5651 | * ) func_append new_inherited_linker_flags " $arg" ;; | |
4910 | 5652 | esac |
4911 | 5653 | continue |
4912 | 5654 | ;; |
4973 | 5715 | # We need an absolute path. |
4974 | 5716 | case $dir in |
4975 | 5717 | [\\/]* | [A-Za-z]:[\\/]*) ;; |
5718 | =*) | |
5719 | func_stripname '=' '' "$dir" | |
5720 | dir=$lt_sysroot$func_stripname_result | |
5721 | ;; | |
4976 | 5722 | *) |
4977 | 5723 | func_fatal_error "only absolute run-paths are allowed" |
4978 | 5724 | ;; |
4979 | 5725 | esac |
4980 | 5726 | case "$xrpath " in |
4981 | 5727 | *" $dir "*) ;; |
4982 | *) xrpath="$xrpath $dir" ;; | |
5728 | *) func_append xrpath " $dir" ;; | |
4983 | 5729 | esac |
4984 | 5730 | continue |
4985 | 5731 | ;; |
5032 | 5778 | for flag in $args; do |
5033 | 5779 | IFS="$save_ifs" |
5034 | 5780 | func_quote_for_eval "$flag" |
5035 | arg="$arg $func_quote_for_eval_result" | |
5036 | compiler_flags="$compiler_flags $func_quote_for_eval_result" | |
5781 | func_append arg " $func_quote_for_eval_result" | |
5782 | func_append compiler_flags " $func_quote_for_eval_result" | |
5037 | 5783 | done |
5038 | 5784 | IFS="$save_ifs" |
5039 | 5785 | func_stripname ' ' '' "$arg" |
5048 | 5794 | for flag in $args; do |
5049 | 5795 | IFS="$save_ifs" |
5050 | 5796 | func_quote_for_eval "$flag" |
5051 | arg="$arg $wl$func_quote_for_eval_result" | |
5052 | compiler_flags="$compiler_flags $wl$func_quote_for_eval_result" | |
5053 | linker_flags="$linker_flags $func_quote_for_eval_result" | |
5797 | func_append arg " $wl$func_quote_for_eval_result" | |
5798 | func_append compiler_flags " $wl$func_quote_for_eval_result" | |
5799 | func_append linker_flags " $func_quote_for_eval_result" | |
5054 | 5800 | done |
5055 | 5801 | IFS="$save_ifs" |
5056 | 5802 | func_stripname ' ' '' "$arg" |
5089 | 5835 | # -p, -pg, --coverage, -fprofile-* profiling flags for GCC |
5090 | 5836 | # @file GCC response files |
5091 | 5837 | # -tp=* Portland pgcc target processor selection |
5838 | # --sysroot=* for sysroot support | |
5839 | # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization | |
5092 | 5840 | -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ |
5093 | -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*) | |
5841 | -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ | |
5842 | -O*|-flto*|-fwhopr*|-fuse-linker-plugin) | |
5094 | 5843 | func_quote_for_eval "$arg" |
5095 | 5844 | arg="$func_quote_for_eval_result" |
5096 | 5845 | func_append compile_command " $arg" |
5097 | 5846 | func_append finalize_command " $arg" |
5098 | compiler_flags="$compiler_flags $arg" | |
5847 | func_append compiler_flags " $arg" | |
5099 | 5848 | continue |
5100 | 5849 | ;; |
5101 | 5850 | |
5107 | 5856 | |
5108 | 5857 | *.$objext) |
5109 | 5858 | # A standard object. |
5110 | objs="$objs $arg" | |
5859 | func_append objs " $arg" | |
5111 | 5860 | ;; |
5112 | 5861 | |
5113 | 5862 | *.lo) |
5138 | 5887 | |
5139 | 5888 | if test "$prev" = dlfiles; then |
5140 | 5889 | if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then |
5141 | dlfiles="$dlfiles $pic_object" | |
5890 | func_append dlfiles " $pic_object" | |
5142 | 5891 | prev= |
5143 | 5892 | continue |
5144 | 5893 | else |
5150 | 5899 | # CHECK ME: I think I busted this. -Ossama |
5151 | 5900 | if test "$prev" = dlprefiles; then |
5152 | 5901 | # Preload the old-style object. |
5153 | dlprefiles="$dlprefiles $pic_object" | |
5902 | func_append dlprefiles " $pic_object" | |
5154 | 5903 | prev= |
5155 | 5904 | fi |
5156 | 5905 | |
5195 | 5944 | |
5196 | 5945 | *.$libext) |
5197 | 5946 | # An archive. |
5198 | deplibs="$deplibs $arg" | |
5199 | old_deplibs="$old_deplibs $arg" | |
5947 | func_append deplibs " $arg" | |
5948 | func_append old_deplibs " $arg" | |
5200 | 5949 | continue |
5201 | 5950 | ;; |
5202 | 5951 | |
5203 | 5952 | *.la) |
5204 | 5953 | # A libtool-controlled library. |
5205 | 5954 | |
5955 | func_resolve_sysroot "$arg" | |
5206 | 5956 | if test "$prev" = dlfiles; then |
5207 | 5957 | # This library was specified with -dlopen. |
5208 | dlfiles="$dlfiles $arg" | |
5958 | func_append dlfiles " $func_resolve_sysroot_result" | |
5209 | 5959 | prev= |
5210 | 5960 | elif test "$prev" = dlprefiles; then |
5211 | 5961 | # The library was specified with -dlpreopen. |
5212 | dlprefiles="$dlprefiles $arg" | |
5962 | func_append dlprefiles " $func_resolve_sysroot_result" | |
5213 | 5963 | prev= |
5214 | 5964 | else |
5215 | deplibs="$deplibs $arg" | |
5965 | func_append deplibs " $func_resolve_sysroot_result" | |
5216 | 5966 | fi |
5217 | 5967 | continue |
5218 | 5968 | ;; |
5259 | 6009 | |
5260 | 6010 | func_dirname "$output" "/" "" |
5261 | 6011 | output_objdir="$func_dirname_result$objdir" |
6012 | func_to_tool_file "$output_objdir/" | |
6013 | tool_output_objdir=$func_to_tool_file_result | |
5262 | 6014 | # Create the object directory. |
5263 | 6015 | func_mkdir_p "$output_objdir" |
5264 | 6016 | |
5279 | 6031 | # Find all interdependent deplibs by searching for libraries |
5280 | 6032 | # that are linked more than once (e.g. -la -lb -la) |
5281 | 6033 | for deplib in $deplibs; do |
5282 | if $opt_duplicate_deps ; then | |
6034 | if $opt_preserve_dup_deps ; then | |
5283 | 6035 | case "$libs " in |
5284 | *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; | |
6036 | *" $deplib "*) func_append specialdeplibs " $deplib" ;; | |
5285 | 6037 | esac |
5286 | 6038 | fi |
5287 | libs="$libs $deplib" | |
6039 | func_append libs " $deplib" | |
5288 | 6040 | done |
5289 | 6041 | |
5290 | 6042 | if test "$linkmode" = lib; then |
5297 | 6049 | if $opt_duplicate_compiler_generated_deps; then |
5298 | 6050 | for pre_post_dep in $predeps $postdeps; do |
5299 | 6051 | case "$pre_post_deps " in |
5300 | *" $pre_post_dep "*) specialdeplibs="$specialdeplibs $pre_post_deps" ;; | |
6052 | *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; | |
5301 | 6053 | esac |
5302 | pre_post_deps="$pre_post_deps $pre_post_dep" | |
6054 | func_append pre_post_deps " $pre_post_dep" | |
5303 | 6055 | done |
5304 | 6056 | fi |
5305 | 6057 | pre_post_deps= |
5366 | 6118 | for lib in $dlprefiles; do |
5367 | 6119 | # Ignore non-libtool-libs |
5368 | 6120 | dependency_libs= |
6121 | func_resolve_sysroot "$lib" | |
5369 | 6122 | case $lib in |
5370 | *.la) func_source "$lib" ;; | |
6123 | *.la) func_source "$func_resolve_sysroot_result" ;; | |
5371 | 6124 | esac |
5372 | 6125 | |
5373 | 6126 | # Collect preopened libtool deplibs, except any this library |
5377 | 6130 | deplib_base=$func_basename_result |
5378 | 6131 | case " $weak_libs " in |
5379 | 6132 | *" $deplib_base "*) ;; |
5380 | *) deplibs="$deplibs $deplib" ;; | |
6133 | *) func_append deplibs " $deplib" ;; | |
5381 | 6134 | esac |
5382 | 6135 | done |
5383 | 6136 | done |
5398 | 6151 | compile_deplibs="$deplib $compile_deplibs" |
5399 | 6152 | finalize_deplibs="$deplib $finalize_deplibs" |
5400 | 6153 | else |
5401 | compiler_flags="$compiler_flags $deplib" | |
6154 | func_append compiler_flags " $deplib" | |
5402 | 6155 | if test "$linkmode" = lib ; then |
5403 | 6156 | case "$new_inherited_linker_flags " in |
5404 | 6157 | *" $deplib "*) ;; |
5405 | * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;; | |
6158 | * ) func_append new_inherited_linker_flags " $deplib" ;; | |
5406 | 6159 | esac |
5407 | 6160 | fi |
5408 | 6161 | fi |
5487 | 6240 | if test "$linkmode" = lib ; then |
5488 | 6241 | case "$new_inherited_linker_flags " in |
5489 | 6242 | *" $deplib "*) ;; |
5490 | * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;; | |
6243 | * ) func_append new_inherited_linker_flags " $deplib" ;; | |
5491 | 6244 | esac |
5492 | 6245 | fi |
5493 | 6246 | fi |
5500 | 6253 | test "$pass" = conv && continue |
5501 | 6254 | newdependency_libs="$deplib $newdependency_libs" |
5502 | 6255 | func_stripname '-L' '' "$deplib" |
5503 | newlib_search_path="$newlib_search_path $func_stripname_result" | |
6256 | func_resolve_sysroot "$func_stripname_result" | |
6257 | func_append newlib_search_path " $func_resolve_sysroot_result" | |
5504 | 6258 | ;; |
5505 | 6259 | prog) |
5506 | 6260 | if test "$pass" = conv; then |
5514 | 6268 | finalize_deplibs="$deplib $finalize_deplibs" |
5515 | 6269 | fi |
5516 | 6270 | func_stripname '-L' '' "$deplib" |
5517 | newlib_search_path="$newlib_search_path $func_stripname_result" | |
6271 | func_resolve_sysroot "$func_stripname_result" | |
6272 | func_append newlib_search_path " $func_resolve_sysroot_result" | |
5518 | 6273 | ;; |
5519 | 6274 | *) |
5520 | 6275 | func_warning "\`-L' is ignored for archives/objects" |
5525 | 6280 | -R*) |
5526 | 6281 | if test "$pass" = link; then |
5527 | 6282 | func_stripname '-R' '' "$deplib" |
5528 | dir=$func_stripname_result | |
6283 | func_resolve_sysroot "$func_stripname_result" | |
6284 | dir=$func_resolve_sysroot_result | |
5529 | 6285 | # Make sure the xrpath contains only unique directories. |
5530 | 6286 | case "$xrpath " in |
5531 | 6287 | *" $dir "*) ;; |
5532 | *) xrpath="$xrpath $dir" ;; | |
6288 | *) func_append xrpath " $dir" ;; | |
5533 | 6289 | esac |
5534 | 6290 | fi |
5535 | 6291 | deplibs="$deplib $deplibs" |
5536 | 6292 | continue |
5537 | 6293 | ;; |
5538 | *.la) lib="$deplib" ;; | |
6294 | *.la) | |
6295 | func_resolve_sysroot "$deplib" | |
6296 | lib=$func_resolve_sysroot_result | |
6297 | ;; | |
5539 | 6298 | *.$libext) |
5540 | 6299 | if test "$pass" = conv; then |
5541 | 6300 | deplibs="$deplib $deplibs" |
5598 | 6357 | if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then |
5599 | 6358 | # If there is no dlopen support or we're linking statically, |
5600 | 6359 | # we need to preload. |
5601 | newdlprefiles="$newdlprefiles $deplib" | |
6360 | func_append newdlprefiles " $deplib" | |
5602 | 6361 | compile_deplibs="$deplib $compile_deplibs" |
5603 | 6362 | finalize_deplibs="$deplib $finalize_deplibs" |
5604 | 6363 | else |
5605 | newdlfiles="$newdlfiles $deplib" | |
6364 | func_append newdlfiles " $deplib" | |
5606 | 6365 | fi |
5607 | 6366 | fi |
5608 | 6367 | continue |
5648 | 6407 | for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do |
5649 | 6408 | case " $new_inherited_linker_flags " in |
5650 | 6409 | *" $tmp_inherited_linker_flag "*) ;; |
5651 | *) new_inherited_linker_flags="$new_inherited_linker_flags $tmp_inherited_linker_flag";; | |
6410 | *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; | |
5652 | 6411 | esac |
5653 | 6412 | done |
5654 | 6413 | fi |
5656 | 6415 | if test "$linkmode,$pass" = "lib,link" || |
5657 | 6416 | test "$linkmode,$pass" = "prog,scan" || |
5658 | 6417 | { test "$linkmode" != prog && test "$linkmode" != lib; }; then |
5659 | test -n "$dlopen" && dlfiles="$dlfiles $dlopen" | |
5660 | test -n "$dlpreopen" && dlprefiles="$dlprefiles $dlpreopen" | |
6418 | test -n "$dlopen" && func_append dlfiles " $dlopen" | |
6419 | test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" | |
5661 | 6420 | fi |
5662 | 6421 | |
5663 | 6422 | if test "$pass" = conv; then |
5668 | 6427 | func_fatal_error "cannot find name of link library for \`$lib'" |
5669 | 6428 | fi |
5670 | 6429 | # It is a libtool convenience library, so add in its objects. |
5671 | convenience="$convenience $ladir/$objdir/$old_library" | |
5672 | old_convenience="$old_convenience $ladir/$objdir/$old_library" | |
6430 | func_append convenience " $ladir/$objdir/$old_library" | |
6431 | func_append old_convenience " $ladir/$objdir/$old_library" | |
5673 | 6432 | elif test "$linkmode" != prog && test "$linkmode" != lib; then |
5674 | 6433 | func_fatal_error "\`$lib' is not a convenience library" |
5675 | 6434 | fi |
5676 | 6435 | tmp_libs= |
5677 | 6436 | for deplib in $dependency_libs; do |
5678 | 6437 | deplibs="$deplib $deplibs" |
5679 | if $opt_duplicate_deps ; then | |
6438 | if $opt_preserve_dup_deps ; then | |
5680 | 6439 | case "$tmp_libs " in |
5681 | *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; | |
6440 | *" $deplib "*) func_append specialdeplibs " $deplib" ;; | |
5682 | 6441 | esac |
5683 | 6442 | fi |
5684 | tmp_libs="$tmp_libs $deplib" | |
6443 | func_append tmp_libs " $deplib" | |
5685 | 6444 | done |
5686 | 6445 | continue |
5687 | 6446 | fi # $pass = conv |
5689 | 6448 | |
5690 | 6449 | # Get the name of the library we link against. |
5691 | 6450 | linklib= |
5692 | for l in $old_library $library_names; do | |
5693 | linklib="$l" | |
5694 | done | |
6451 | if test -n "$old_library" && | |
6452 | { test "$prefer_static_libs" = yes || | |
6453 | test "$prefer_static_libs,$installed" = "built,no"; }; then | |
6454 | linklib=$old_library | |
6455 | else | |
6456 | for l in $old_library $library_names; do | |
6457 | linklib="$l" | |
6458 | done | |
6459 | fi | |
5695 | 6460 | if test -z "$linklib"; then |
5696 | 6461 | func_fatal_error "cannot find name of link library for \`$lib'" |
5697 | 6462 | fi |
5708 | 6473 | # statically, we need to preload. We also need to preload any |
5709 | 6474 | # dependent libraries so libltdl's deplib preloader doesn't |
5710 | 6475 | # bomb out in the load deplibs phase. |
5711 | dlprefiles="$dlprefiles $lib $dependency_libs" | |
6476 | func_append dlprefiles " $lib $dependency_libs" | |
5712 | 6477 | else |
5713 | newdlfiles="$newdlfiles $lib" | |
6478 | func_append newdlfiles " $lib" | |
5714 | 6479 | fi |
5715 | 6480 | continue |
5716 | 6481 | fi # $pass = dlopen |
5732 | 6497 | |
5733 | 6498 | # Find the relevant object directory and library name. |
5734 | 6499 | if test "X$installed" = Xyes; then |
5735 | if test ! -f "$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then | |
6500 | if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then | |
5736 | 6501 | func_warning "library \`$lib' was moved." |
5737 | 6502 | dir="$ladir" |
5738 | 6503 | absdir="$abs_ladir" |
5739 | 6504 | libdir="$abs_ladir" |
5740 | 6505 | else |
5741 | dir="$libdir" | |
5742 | absdir="$libdir" | |
6506 | dir="$lt_sysroot$libdir" | |
6507 | absdir="$lt_sysroot$libdir" | |
5743 | 6508 | fi |
5744 | 6509 | test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes |
5745 | 6510 | else |
5747 | 6512 | dir="$ladir" |
5748 | 6513 | absdir="$abs_ladir" |
5749 | 6514 | # Remove this search path later |
5750 | notinst_path="$notinst_path $abs_ladir" | |
6515 | func_append notinst_path " $abs_ladir" | |
5751 | 6516 | else |
5752 | 6517 | dir="$ladir/$objdir" |
5753 | 6518 | absdir="$abs_ladir/$objdir" |
5754 | 6519 | # Remove this search path later |
5755 | notinst_path="$notinst_path $abs_ladir" | |
6520 | func_append notinst_path " $abs_ladir" | |
5756 | 6521 | fi |
5757 | 6522 | fi # $installed = yes |
5758 | 6523 | func_stripname 'lib' '.la' "$laname" |
5763 | 6528 | if test -z "$libdir" && test "$linkmode" = prog; then |
5764 | 6529 | func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'" |
5765 | 6530 | fi |
5766 | # Prefer using a static library (so that no silly _DYNAMIC symbols | |
5767 | # are required to link). | |
5768 | if test -n "$old_library"; then | |
5769 | newdlprefiles="$newdlprefiles $dir/$old_library" | |
5770 | # Keep a list of preopened convenience libraries to check | |
5771 | # that they are being used correctly in the link pass. | |
5772 | test -z "$libdir" && \ | |
5773 | dlpreconveniencelibs="$dlpreconveniencelibs $dir/$old_library" | |
5774 | # Otherwise, use the dlname, so that lt_dlopen finds it. | |
5775 | elif test -n "$dlname"; then | |
5776 | newdlprefiles="$newdlprefiles $dir/$dlname" | |
5777 | else | |
5778 | newdlprefiles="$newdlprefiles $dir/$linklib" | |
5779 | fi | |
6531 | case "$host" in | |
6532 | # special handling for platforms with PE-DLLs. | |
6533 | *cygwin* | *mingw* | *cegcc* ) | |
6534 | # Linker will automatically link against shared library if both | |
6535 | # static and shared are present. Therefore, ensure we extract | |
6536 | # symbols from the import library if a shared library is present | |
6537 | # (otherwise, the dlopen module name will be incorrect). We do | |
6538 | # this by putting the import library name into $newdlprefiles. | |
6539 | # We recover the dlopen module name by 'saving' the la file | |
6540 | # name in a special purpose variable, and (later) extracting the | |
6541 | # dlname from the la file. | |
6542 | if test -n "$dlname"; then | |
6543 | func_tr_sh "$dir/$linklib" | |
6544 | eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" | |
6545 | func_append newdlprefiles " $dir/$linklib" | |
6546 | else | |
6547 | func_append newdlprefiles " $dir/$old_library" | |
6548 | # Keep a list of preopened convenience libraries to check | |
6549 | # that they are being used correctly in the link pass. | |
6550 | test -z "$libdir" && \ | |
6551 | func_append dlpreconveniencelibs " $dir/$old_library" | |
6552 | fi | |
6553 | ;; | |
6554 | * ) | |
6555 | # Prefer using a static library (so that no silly _DYNAMIC symbols | |
6556 | # are required to link). | |
6557 | if test -n "$old_library"; then | |
6558 | func_append newdlprefiles " $dir/$old_library" | |
6559 | # Keep a list of preopened convenience libraries to check | |
6560 | # that they are being used correctly in the link pass. | |
6561 | test -z "$libdir" && \ | |
6562 | func_append dlpreconveniencelibs " $dir/$old_library" | |
6563 | # Otherwise, use the dlname, so that lt_dlopen finds it. | |
6564 | elif test -n "$dlname"; then | |
6565 | func_append newdlprefiles " $dir/$dlname" | |
6566 | else | |
6567 | func_append newdlprefiles " $dir/$linklib" | |
6568 | fi | |
6569 | ;; | |
6570 | esac | |
5780 | 6571 | fi # $pass = dlpreopen |
5781 | 6572 | |
5782 | 6573 | if test -z "$libdir"; then |
5794 | 6585 | |
5795 | 6586 | |
5796 | 6587 | if test "$linkmode" = prog && test "$pass" != link; then |
5797 | newlib_search_path="$newlib_search_path $ladir" | |
6588 | func_append newlib_search_path " $ladir" | |
5798 | 6589 | deplibs="$lib $deplibs" |
5799 | 6590 | |
5800 | 6591 | linkalldeplibs=no |
5807 | 6598 | for deplib in $dependency_libs; do |
5808 | 6599 | case $deplib in |
5809 | 6600 | -L*) func_stripname '-L' '' "$deplib" |
5810 | newlib_search_path="$newlib_search_path $func_stripname_result" | |
6601 | func_resolve_sysroot "$func_stripname_result" | |
6602 | func_append newlib_search_path " $func_resolve_sysroot_result" | |
5811 | 6603 | ;; |
5812 | 6604 | esac |
5813 | 6605 | # Need to link against all dependency_libs? |
5818 | 6610 | # or/and link against static libraries |
5819 | 6611 | newdependency_libs="$deplib $newdependency_libs" |
5820 | 6612 | fi |
5821 | if $opt_duplicate_deps ; then | |
6613 | if $opt_preserve_dup_deps ; then | |
5822 | 6614 | case "$tmp_libs " in |
5823 | *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; | |
6615 | *" $deplib "*) func_append specialdeplibs " $deplib" ;; | |
5824 | 6616 | esac |
5825 | 6617 | fi |
5826 | tmp_libs="$tmp_libs $deplib" | |
6618 | func_append tmp_libs " $deplib" | |
5827 | 6619 | done # for deplib |
5828 | 6620 | continue |
5829 | 6621 | fi # $linkmode = prog... |
5838 | 6630 | # Make sure the rpath contains only unique directories. |
5839 | 6631 | case "$temp_rpath:" in |
5840 | 6632 | *"$absdir:"*) ;; |
5841 | *) temp_rpath="$temp_rpath$absdir:" ;; | |
6633 | *) func_append temp_rpath "$absdir:" ;; | |
5842 | 6634 | esac |
5843 | 6635 | fi |
5844 | 6636 | |
5850 | 6642 | *) |
5851 | 6643 | case "$compile_rpath " in |
5852 | 6644 | *" $absdir "*) ;; |
5853 | *) compile_rpath="$compile_rpath $absdir" | |
6645 | *) func_append compile_rpath " $absdir" ;; | |
5854 | 6646 | esac |
5855 | 6647 | ;; |
5856 | 6648 | esac |
5859 | 6651 | *) |
5860 | 6652 | case "$finalize_rpath " in |
5861 | 6653 | *" $libdir "*) ;; |
5862 | *) finalize_rpath="$finalize_rpath $libdir" | |
6654 | *) func_append finalize_rpath " $libdir" ;; | |
5863 | 6655 | esac |
5864 | 6656 | ;; |
5865 | 6657 | esac |
5884 | 6676 | case $host in |
5885 | 6677 | *cygwin* | *mingw* | *cegcc*) |
5886 | 6678 | # No point in relinking DLLs because paths are not encoded |
5887 | notinst_deplibs="$notinst_deplibs $lib" | |
6679 | func_append notinst_deplibs " $lib" | |
5888 | 6680 | need_relink=no |
5889 | 6681 | ;; |
5890 | 6682 | *) |
5891 | 6683 | if test "$installed" = no; then |
5892 | notinst_deplibs="$notinst_deplibs $lib" | |
6684 | func_append notinst_deplibs " $lib" | |
5893 | 6685 | need_relink=yes |
5894 | 6686 | fi |
5895 | 6687 | ;; |
5924 | 6716 | *) |
5925 | 6717 | case "$compile_rpath " in |
5926 | 6718 | *" $absdir "*) ;; |
5927 | *) compile_rpath="$compile_rpath $absdir" | |
6719 | *) func_append compile_rpath " $absdir" ;; | |
5928 | 6720 | esac |
5929 | 6721 | ;; |
5930 | 6722 | esac |
5933 | 6725 | *) |
5934 | 6726 | case "$finalize_rpath " in |
5935 | 6727 | *" $libdir "*) ;; |
5936 | *) finalize_rpath="$finalize_rpath $libdir" | |
6728 | *) func_append finalize_rpath " $libdir" ;; | |
5937 | 6729 | esac |
5938 | 6730 | ;; |
5939 | 6731 | esac |
5987 | 6779 | linklib=$newlib |
5988 | 6780 | fi # test -n "$old_archive_from_expsyms_cmds" |
5989 | 6781 | |
5990 | if test "$linkmode" = prog || test "$mode" != relink; then | |
6782 | if test "$linkmode" = prog || test "$opt_mode" != relink; then | |
5991 | 6783 | add_shlibpath= |
5992 | 6784 | add_dir= |
5993 | 6785 | add= |
6043 | 6835 | if test -n "$inst_prefix_dir"; then |
6044 | 6836 | case $libdir in |
6045 | 6837 | [\\/]*) |
6046 | add_dir="$add_dir -L$inst_prefix_dir$libdir" | |
6838 | func_append add_dir " -L$inst_prefix_dir$libdir" | |
6047 | 6839 | ;; |
6048 | 6840 | esac |
6049 | 6841 | fi |
6065 | 6857 | if test -n "$add_shlibpath"; then |
6066 | 6858 | case :$compile_shlibpath: in |
6067 | 6859 | *":$add_shlibpath:"*) ;; |
6068 | *) compile_shlibpath="$compile_shlibpath$add_shlibpath:" ;; | |
6860 | *) func_append compile_shlibpath "$add_shlibpath:" ;; | |
6069 | 6861 | esac |
6070 | 6862 | fi |
6071 | 6863 | if test "$linkmode" = prog; then |
6079 | 6871 | test "$hardcode_shlibpath_var" = yes; then |
6080 | 6872 | case :$finalize_shlibpath: in |
6081 | 6873 | *":$libdir:"*) ;; |
6082 | *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; | |
6874 | *) func_append finalize_shlibpath "$libdir:" ;; | |
6083 | 6875 | esac |
6084 | 6876 | fi |
6085 | 6877 | fi |
6086 | 6878 | fi |
6087 | 6879 | |
6088 | if test "$linkmode" = prog || test "$mode" = relink; then | |
6880 | if test "$linkmode" = prog || test "$opt_mode" = relink; then | |
6089 | 6881 | add_shlibpath= |
6090 | 6882 | add_dir= |
6091 | 6883 | add= |
6099 | 6891 | elif test "$hardcode_shlibpath_var" = yes; then |
6100 | 6892 | case :$finalize_shlibpath: in |
6101 | 6893 | *":$libdir:"*) ;; |
6102 | *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; | |
6894 | *) func_append finalize_shlibpath "$libdir:" ;; | |
6103 | 6895 | esac |
6104 | 6896 | add="-l$name" |
6105 | 6897 | elif test "$hardcode_automatic" = yes; then |
6116 | 6908 | if test -n "$inst_prefix_dir"; then |
6117 | 6909 | case $libdir in |
6118 | 6910 | [\\/]*) |
6119 | add_dir="$add_dir -L$inst_prefix_dir$libdir" | |
6911 | func_append add_dir " -L$inst_prefix_dir$libdir" | |
6120 | 6912 | ;; |
6121 | 6913 | esac |
6122 | 6914 | fi |
6193 | 6985 | temp_xrpath=$func_stripname_result |
6194 | 6986 | case " $xrpath " in |
6195 | 6987 | *" $temp_xrpath "*) ;; |
6196 | *) xrpath="$xrpath $temp_xrpath";; | |
6988 | *) func_append xrpath " $temp_xrpath";; | |
6197 | 6989 | esac;; |
6198 | *) temp_deplibs="$temp_deplibs $libdir";; | |
6990 | *) func_append temp_deplibs " $libdir";; | |
6199 | 6991 | esac |
6200 | 6992 | done |
6201 | 6993 | dependency_libs="$temp_deplibs" |
6202 | 6994 | fi |
6203 | 6995 | |
6204 | newlib_search_path="$newlib_search_path $absdir" | |
6996 | func_append newlib_search_path " $absdir" | |
6205 | 6997 | # Link against this library |
6206 | 6998 | test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" |
6207 | 6999 | # ... and its dependency_libs |
6208 | 7000 | tmp_libs= |
6209 | 7001 | for deplib in $dependency_libs; do |
6210 | 7002 | newdependency_libs="$deplib $newdependency_libs" |
6211 | if $opt_duplicate_deps ; then | |
7003 | case $deplib in | |
7004 | -L*) func_stripname '-L' '' "$deplib" | |
7005 | func_resolve_sysroot "$func_stripname_result";; | |
7006 | *) func_resolve_sysroot "$deplib" ;; | |
7007 | esac | |
7008 | if $opt_preserve_dup_deps ; then | |
6212 | 7009 | case "$tmp_libs " in |
6213 | *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; | |
7010 | *" $func_resolve_sysroot_result "*) | |
7011 | func_append specialdeplibs " $func_resolve_sysroot_result" ;; | |
6214 | 7012 | esac |
6215 | 7013 | fi |
6216 | tmp_libs="$tmp_libs $deplib" | |
7014 | func_append tmp_libs " $func_resolve_sysroot_result" | |
6217 | 7015 | done |
6218 | 7016 | |
6219 | 7017 | if test "$link_all_deplibs" != no; then |
6223 | 7021 | case $deplib in |
6224 | 7022 | -L*) path="$deplib" ;; |
6225 | 7023 | *.la) |
7024 | func_resolve_sysroot "$deplib" | |
7025 | deplib=$func_resolve_sysroot_result | |
6226 | 7026 | func_dirname "$deplib" "" "." |
6227 | dir="$func_dirname_result" | |
7027 | dir=$func_dirname_result | |
6228 | 7028 | # We need an absolute path. |
6229 | 7029 | case $dir in |
6230 | 7030 | [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; |
6251 | 7051 | if test -z "$darwin_install_name"; then |
6252 | 7052 | darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` |
6253 | 7053 | fi |
6254 | compiler_flags="$compiler_flags ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}" | |
6255 | linker_flags="$linker_flags -dylib_file ${darwin_install_name}:${depdepl}" | |
7054 | func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}" | |
7055 | func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}" | |
6256 | 7056 | path= |
6257 | 7057 | fi |
6258 | 7058 | fi |
6302 | 7102 | for dir in $newlib_search_path; do |
6303 | 7103 | case "$lib_search_path " in |
6304 | 7104 | *" $dir "*) ;; |
6305 | *) lib_search_path="$lib_search_path $dir" ;; | |
7105 | *) func_append lib_search_path " $dir" ;; | |
6306 | 7106 | esac |
6307 | 7107 | done |
6308 | 7108 | newlib_search_path= |
6360 | 7160 | -L*) |
6361 | 7161 | case " $tmp_libs " in |
6362 | 7162 | *" $deplib "*) ;; |
6363 | *) tmp_libs="$tmp_libs $deplib" ;; | |
7163 | *) func_append tmp_libs " $deplib" ;; | |
6364 | 7164 | esac |
6365 | 7165 | ;; |
6366 | *) tmp_libs="$tmp_libs $deplib" ;; | |
7166 | *) func_append tmp_libs " $deplib" ;; | |
6367 | 7167 | esac |
6368 | 7168 | done |
6369 | 7169 | eval $var=\"$tmp_libs\" |
6379 | 7179 | ;; |
6380 | 7180 | esac |
6381 | 7181 | if test -n "$i" ; then |
6382 | tmp_libs="$tmp_libs $i" | |
7182 | func_append tmp_libs " $i" | |
6383 | 7183 | fi |
6384 | 7184 | done |
6385 | 7185 | dependency_libs=$tmp_libs |
6420 | 7220 | # Now set the variables for building old libraries. |
6421 | 7221 | build_libtool_libs=no |
6422 | 7222 | oldlibs="$output" |
6423 | objs="$objs$old_deplibs" | |
7223 | func_append objs "$old_deplibs" | |
6424 | 7224 | ;; |
6425 | 7225 | |
6426 | 7226 | lib) |
6456 | 7256 | echo |
6457 | 7257 | $ECHO "*** Warning: Linking the shared library $output against the non-libtool" |
6458 | 7258 | $ECHO "*** objects $objs is not portable!" |
6459 | libobjs="$libobjs $objs" | |
7259 | func_append libobjs " $objs" | |
6460 | 7260 | fi |
6461 | 7261 | fi |
6462 | 7262 | |
6654 | 7454 | done |
6655 | 7455 | |
6656 | 7456 | # Make executables depend on our current version. |
6657 | verstring="$verstring:${current}.0" | |
7457 | func_append verstring ":${current}.0" | |
6658 | 7458 | ;; |
6659 | 7459 | |
6660 | 7460 | qnx) |
6722 | 7522 | fi |
6723 | 7523 | |
6724 | 7524 | func_generate_dlsyms "$libname" "$libname" "yes" |
6725 | libobjs="$libobjs $symfileobj" | |
7525 | func_append libobjs " $symfileobj" | |
6726 | 7526 | test "X$libobjs" = "X " && libobjs= |
6727 | 7527 | |
6728 | if test "$mode" != relink; then | |
7528 | if test "$opt_mode" != relink; then | |
6729 | 7529 | # Remove our outputs, but don't remove object files since they |
6730 | 7530 | # may have been created when compiling PIC objects. |
6731 | 7531 | removelist= |
6741 | 7541 | continue |
6742 | 7542 | fi |
6743 | 7543 | fi |
6744 | removelist="$removelist $p" | |
7544 | func_append removelist " $p" | |
6745 | 7545 | ;; |
6746 | 7546 | *) ;; |
6747 | 7547 | esac |
6752 | 7552 | |
6753 | 7553 | # Now set the variables for building old libraries. |
6754 | 7554 | if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then |
6755 | oldlibs="$oldlibs $output_objdir/$libname.$libext" | |
7555 | func_append oldlibs " $output_objdir/$libname.$libext" | |
6756 | 7556 | |
6757 | 7557 | # Transform .lo files to .o files. |
6758 | 7558 | oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP` |
6769 | 7569 | # If the user specified any rpath flags, then add them. |
6770 | 7570 | temp_xrpath= |
6771 | 7571 | for libdir in $xrpath; do |
6772 | temp_xrpath="$temp_xrpath -R$libdir" | |
7572 | func_replace_sysroot "$libdir" | |
7573 | func_append temp_xrpath " -R$func_replace_sysroot_result" | |
6773 | 7574 | case "$finalize_rpath " in |
6774 | 7575 | *" $libdir "*) ;; |
6775 | *) finalize_rpath="$finalize_rpath $libdir" ;; | |
7576 | *) func_append finalize_rpath " $libdir" ;; | |
6776 | 7577 | esac |
6777 | 7578 | done |
6778 | 7579 | if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then |
6786 | 7587 | for lib in $old_dlfiles; do |
6787 | 7588 | case " $dlprefiles $dlfiles " in |
6788 | 7589 | *" $lib "*) ;; |
6789 | *) dlfiles="$dlfiles $lib" ;; | |
7590 | *) func_append dlfiles " $lib" ;; | |
6790 | 7591 | esac |
6791 | 7592 | done |
6792 | 7593 | |
6796 | 7597 | for lib in $old_dlprefiles; do |
6797 | 7598 | case "$dlprefiles " in |
6798 | 7599 | *" $lib "*) ;; |
6799 | *) dlprefiles="$dlprefiles $lib" ;; | |
7600 | *) func_append dlprefiles " $lib" ;; | |
6800 | 7601 | esac |
6801 | 7602 | done |
6802 | 7603 | |
6808 | 7609 | ;; |
6809 | 7610 | *-*-rhapsody* | *-*-darwin1.[012]) |
6810 | 7611 | # Rhapsody C library is in the System framework |
6811 | deplibs="$deplibs System.ltframework" | |
7612 | func_append deplibs " System.ltframework" | |
6812 | 7613 | ;; |
6813 | 7614 | *-*-netbsd*) |
6814 | 7615 | # Don't link with libc until the a.out ld.so is fixed. |
6825 | 7626 | *) |
6826 | 7627 | # Add libc to deplibs on all other systems if necessary. |
6827 | 7628 | if test "$build_libtool_need_lc" = "yes"; then |
6828 | deplibs="$deplibs -lc" | |
7629 | func_append deplibs " -lc" | |
6829 | 7630 | fi |
6830 | 7631 | ;; |
6831 | 7632 | esac |
6874 | 7675 | if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then |
6875 | 7676 | case " $predeps $postdeps " in |
6876 | 7677 | *" $i "*) |
6877 | newdeplibs="$newdeplibs $i" | |
7678 | func_append newdeplibs " $i" | |
6878 | 7679 | i="" |
6879 | 7680 | ;; |
6880 | 7681 | esac |
6885 | 7686 | set dummy $deplib_matches; shift |
6886 | 7687 | deplib_match=$1 |
6887 | 7688 | if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then |
6888 | newdeplibs="$newdeplibs $i" | |
7689 | func_append newdeplibs " $i" | |
6889 | 7690 | else |
6890 | 7691 | droppeddeps=yes |
6891 | 7692 | echo |
6899 | 7700 | fi |
6900 | 7701 | ;; |
6901 | 7702 | *) |
6902 | newdeplibs="$newdeplibs $i" | |
7703 | func_append newdeplibs " $i" | |
6903 | 7704 | ;; |
6904 | 7705 | esac |
6905 | 7706 | done |
6917 | 7718 | if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then |
6918 | 7719 | case " $predeps $postdeps " in |
6919 | 7720 | *" $i "*) |
6920 | newdeplibs="$newdeplibs $i" | |
7721 | func_append newdeplibs " $i" | |
6921 | 7722 | i="" |
6922 | 7723 | ;; |
6923 | 7724 | esac |
6928 | 7729 | set dummy $deplib_matches; shift |
6929 | 7730 | deplib_match=$1 |
6930 | 7731 | if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then |
6931 | newdeplibs="$newdeplibs $i" | |
7732 | func_append newdeplibs " $i" | |
6932 | 7733 | else |
6933 | 7734 | droppeddeps=yes |
6934 | 7735 | echo |
6950 | 7751 | fi |
6951 | 7752 | ;; |
6952 | 7753 | *) |
6953 | newdeplibs="$newdeplibs $i" | |
7754 | func_append newdeplibs " $i" | |
6954 | 7755 | ;; |
6955 | 7756 | esac |
6956 | 7757 | done |
6967 | 7768 | if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then |
6968 | 7769 | case " $predeps $postdeps " in |
6969 | 7770 | *" $a_deplib "*) |
6970 | newdeplibs="$newdeplibs $a_deplib" | |
7771 | func_append newdeplibs " $a_deplib" | |
6971 | 7772 | a_deplib="" |
6972 | 7773 | ;; |
6973 | 7774 | esac |
6974 | 7775 | fi |
6975 | 7776 | if test -n "$a_deplib" ; then |
6976 | 7777 | libname=`eval "\\$ECHO \"$libname_spec\""` |
7778 | if test -n "$file_magic_glob"; then | |
7779 | libnameglob=`func_echo_all "$libname" | $SED -e $file_magic_glob` | |
7780 | else | |
7781 | libnameglob=$libname | |
7782 | fi | |
7783 | test "$want_nocaseglob" = yes && nocaseglob=`shopt -p nocaseglob` | |
6977 | 7784 | for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do |
6978 | potential_libs=`ls $i/$libname[.-]* 2>/dev/null` | |
7785 | if test "$want_nocaseglob" = yes; then | |
7786 | shopt -s nocaseglob | |
7787 | potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` | |
7788 | $nocaseglob | |
7789 | else | |
7790 | potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` | |
7791 | fi | |
6979 | 7792 | for potent_lib in $potential_libs; do |
6980 | 7793 | # Follow soft links. |
6981 | 7794 | if ls -lLd "$potent_lib" 2>/dev/null | |
6998 | 7811 | if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | |
6999 | 7812 | $SED -e 10q | |
7000 | 7813 | $EGREP "$file_magic_regex" > /dev/null; then |
7001 | newdeplibs="$newdeplibs $a_deplib" | |
7814 | func_append newdeplibs " $a_deplib" | |
7002 | 7815 | a_deplib="" |
7003 | 7816 | break 2 |
7004 | 7817 | fi |
7023 | 7836 | ;; |
7024 | 7837 | *) |
7025 | 7838 | # Add a -L argument. |
7026 | newdeplibs="$newdeplibs $a_deplib" | |
7839 | func_append newdeplibs " $a_deplib" | |
7027 | 7840 | ;; |
7028 | 7841 | esac |
7029 | 7842 | done # Gone through all deplibs. |
7039 | 7852 | if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then |
7040 | 7853 | case " $predeps $postdeps " in |
7041 | 7854 | *" $a_deplib "*) |
7042 | newdeplibs="$newdeplibs $a_deplib" | |
7855 | func_append newdeplibs " $a_deplib" | |
7043 | 7856 | a_deplib="" |
7044 | 7857 | ;; |
7045 | 7858 | esac |
7052 | 7865 | potlib="$potent_lib" # see symlink-check above in file_magic test |
7053 | 7866 | if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ |
7054 | 7867 | $EGREP "$match_pattern_regex" > /dev/null; then |
7055 | newdeplibs="$newdeplibs $a_deplib" | |
7868 | func_append newdeplibs " $a_deplib" | |
7056 | 7869 | a_deplib="" |
7057 | 7870 | break 2 |
7058 | 7871 | fi |
7077 | 7890 | ;; |
7078 | 7891 | *) |
7079 | 7892 | # Add a -L argument. |
7080 | newdeplibs="$newdeplibs $a_deplib" | |
7893 | func_append newdeplibs " $a_deplib" | |
7081 | 7894 | ;; |
7082 | 7895 | esac |
7083 | 7896 | done # Gone through all deplibs. |
7181 | 7994 | *) |
7182 | 7995 | case " $deplibs " in |
7183 | 7996 | *" -L$path/$objdir "*) |
7184 | new_libs="$new_libs -L$path/$objdir" ;; | |
7997 | func_append new_libs " -L$path/$objdir" ;; | |
7185 | 7998 | esac |
7186 | 7999 | ;; |
7187 | 8000 | esac |
7191 | 8004 | -L*) |
7192 | 8005 | case " $new_libs " in |
7193 | 8006 | *" $deplib "*) ;; |
7194 | *) new_libs="$new_libs $deplib" ;; | |
8007 | *) func_append new_libs " $deplib" ;; | |
7195 | 8008 | esac |
7196 | 8009 | ;; |
7197 | *) new_libs="$new_libs $deplib" ;; | |
8010 | *) func_append new_libs " $deplib" ;; | |
7198 | 8011 | esac |
7199 | 8012 | done |
7200 | 8013 | deplibs="$new_libs" |
7211 | 8024 | hardcode_libdirs= |
7212 | 8025 | dep_rpath= |
7213 | 8026 | rpath="$finalize_rpath" |
7214 | test "$mode" != relink && rpath="$compile_rpath$rpath" | |
8027 | test "$opt_mode" != relink && rpath="$compile_rpath$rpath" | |
7215 | 8028 | for libdir in $rpath; do |
7216 | 8029 | if test -n "$hardcode_libdir_flag_spec"; then |
7217 | 8030 | if test -n "$hardcode_libdir_separator"; then |
8031 | func_replace_sysroot "$libdir" | |
8032 | libdir=$func_replace_sysroot_result | |
7218 | 8033 | if test -z "$hardcode_libdirs"; then |
7219 | 8034 | hardcode_libdirs="$libdir" |
7220 | 8035 | else |
7223 | 8038 | *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) |
7224 | 8039 | ;; |
7225 | 8040 | *) |
7226 | hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" | |
8041 | func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" | |
7227 | 8042 | ;; |
7228 | 8043 | esac |
7229 | 8044 | fi |
7230 | 8045 | else |
7231 | 8046 | eval flag=\"$hardcode_libdir_flag_spec\" |
7232 | dep_rpath="$dep_rpath $flag" | |
8047 | func_append dep_rpath " $flag" | |
7233 | 8048 | fi |
7234 | 8049 | elif test -n "$runpath_var"; then |
7235 | 8050 | case "$perm_rpath " in |
7236 | 8051 | *" $libdir "*) ;; |
7237 | *) perm_rpath="$perm_rpath $libdir" ;; | |
8052 | *) func_append perm_rpath " $libdir" ;; | |
7238 | 8053 | esac |
7239 | 8054 | fi |
7240 | 8055 | done |
7252 | 8067 | # We should set the runpath_var. |
7253 | 8068 | rpath= |
7254 | 8069 | for dir in $perm_rpath; do |
7255 | rpath="$rpath$dir:" | |
8070 | func_append rpath "$dir:" | |
7256 | 8071 | done |
7257 | 8072 | eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" |
7258 | 8073 | fi |
7260 | 8075 | fi |
7261 | 8076 | |
7262 | 8077 | shlibpath="$finalize_shlibpath" |
7263 | test "$mode" != relink && shlibpath="$compile_shlibpath$shlibpath" | |
8078 | test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath" | |
7264 | 8079 | if test -n "$shlibpath"; then |
7265 | 8080 | eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" |
7266 | 8081 | fi |
7286 | 8101 | linknames= |
7287 | 8102 | for link |
7288 | 8103 | do |
7289 | linknames="$linknames $link" | |
8104 | func_append linknames " $link" | |
7290 | 8105 | done |
7291 | 8106 | |
7292 | 8107 | # Use standard objects if they are pic |
7297 | 8112 | if test -n "$export_symbols" && test -n "$include_expsyms"; then |
7298 | 8113 | $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" |
7299 | 8114 | export_symbols="$output_objdir/$libname.uexp" |
7300 | delfiles="$delfiles $export_symbols" | |
8115 | func_append delfiles " $export_symbols" | |
7301 | 8116 | fi |
7302 | 8117 | |
7303 | 8118 | orig_export_symbols= |
7328 | 8143 | $opt_dry_run || $RM $export_symbols |
7329 | 8144 | cmds=$export_symbols_cmds |
7330 | 8145 | save_ifs="$IFS"; IFS='~' |
7331 | for cmd in $cmds; do | |
8146 | for cmd1 in $cmds; do | |
7332 | 8147 | IFS="$save_ifs" |
7333 | eval cmd=\"$cmd\" | |
7334 | func_len " $cmd" | |
7335 | len=$func_len_result | |
7336 | if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then | |
8148 | # Take the normal branch if the nm_file_list_spec branch | |
8149 | # doesn't work or if tool conversion is not needed. | |
8150 | case $nm_file_list_spec~$to_tool_file_cmd in | |
8151 | *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) | |
8152 | try_normal_branch=yes | |
8153 | eval cmd=\"$cmd1\" | |
8154 | func_len " $cmd" | |
8155 | len=$func_len_result | |
8156 | ;; | |
8157 | *) | |
8158 | try_normal_branch=no | |
8159 | ;; | |
8160 | esac | |
8161 | if test "$try_normal_branch" = yes \ | |
8162 | && { test "$len" -lt "$max_cmd_len" \ | |
8163 | || test "$max_cmd_len" -le -1; } | |
8164 | then | |
7337 | 8165 | func_show_eval "$cmd" 'exit $?' |
8166 | skipped_export=false | |
8167 | elif test -n "$nm_file_list_spec"; then | |
8168 | func_basename "$output" | |
8169 | output_la=$func_basename_result | |
8170 | save_libobjs=$libobjs | |
8171 | save_output=$output | |
8172 | output=${output_objdir}/${output_la}.nm | |
8173 | func_to_tool_file "$output" | |
8174 | libobjs=$nm_file_list_spec$func_to_tool_file_result | |
8175 | func_append delfiles " $output" | |
8176 | func_verbose "creating $NM input file list: $output" | |
8177 | for obj in $save_libobjs; do | |
8178 | func_to_tool_file "$obj" | |
8179 | $ECHO "$func_to_tool_file_result" | |
8180 | done > "$output" | |
8181 | eval cmd=\"$cmd1\" | |
8182 | func_show_eval "$cmd" 'exit $?' | |
8183 | output=$save_output | |
8184 | libobjs=$save_libobjs | |
7338 | 8185 | skipped_export=false |
7339 | 8186 | else |
7340 | 8187 | # The command line is too long to execute in one step. |
7368 | 8215 | # global variables. join(1) would be nice here, but unfortunately |
7369 | 8216 | # isn't a blessed tool. |
7370 | 8217 | $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter |
7371 | delfiles="$delfiles $export_symbols $output_objdir/$libname.filter" | |
8218 | func_append delfiles " $export_symbols $output_objdir/$libname.filter" | |
7372 | 8219 | export_symbols=$output_objdir/$libname.def |
7373 | 8220 | $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols |
7374 | 8221 | fi |
7378 | 8225 | case " $convenience " in |
7379 | 8226 | *" $test_deplib "*) ;; |
7380 | 8227 | *) |
7381 | tmp_deplibs="$tmp_deplibs $test_deplib" | |
8228 | func_append tmp_deplibs " $test_deplib" | |
7382 | 8229 | ;; |
7383 | 8230 | esac |
7384 | 8231 | done |
7398 | 8245 | test "X$libobjs" = "X " && libobjs= |
7399 | 8246 | else |
7400 | 8247 | gentop="$output_objdir/${outputname}x" |
7401 | generated="$generated $gentop" | |
8248 | func_append generated " $gentop" | |
7402 | 8249 | |
7403 | 8250 | func_extract_archives $gentop $convenience |
7404 | libobjs="$libobjs $func_extract_archives_result" | |
8251 | func_append libobjs " $func_extract_archives_result" | |
7405 | 8252 | test "X$libobjs" = "X " && libobjs= |
7406 | 8253 | fi |
7407 | 8254 | fi |
7408 | 8255 | |
7409 | 8256 | if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then |
7410 | 8257 | eval flag=\"$thread_safe_flag_spec\" |
7411 | linker_flags="$linker_flags $flag" | |
8258 | func_append linker_flags " $flag" | |
7412 | 8259 | fi |
7413 | 8260 | |
7414 | 8261 | # Make a backup of the uninstalled library when relinking |
7415 | if test "$mode" = relink; then | |
8262 | if test "$opt_mode" = relink; then | |
7416 | 8263 | $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? |
7417 | 8264 | fi |
7418 | 8265 | |
7474 | 8321 | echo 'INPUT (' > $output |
7475 | 8322 | for obj in $save_libobjs |
7476 | 8323 | do |
7477 | $ECHO "$obj" >> $output | |
8324 | func_to_tool_file "$obj" | |
8325 | $ECHO "$func_to_tool_file_result" >> $output | |
7478 | 8326 | done |
7479 | 8327 | echo ')' >> $output |
7480 | delfiles="$delfiles $output" | |
8328 | func_append delfiles " $output" | |
8329 | func_to_tool_file "$output" | |
8330 | output=$func_to_tool_file_result | |
7481 | 8331 | elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then |
7482 | 8332 | output=${output_objdir}/${output_la}.lnk |
7483 | 8333 | func_verbose "creating linker input file list: $output" |
7491 | 8341 | fi |
7492 | 8342 | for obj |
7493 | 8343 | do |
7494 | $ECHO "$obj" >> $output | |
8344 | func_to_tool_file "$obj" | |
8345 | $ECHO "$func_to_tool_file_result" >> $output | |
7495 | 8346 | done |
7496 | delfiles="$delfiles $output" | |
7497 | output=$firstobj\"$file_list_spec$output\" | |
8347 | func_append delfiles " $output" | |
8348 | func_to_tool_file "$output" | |
8349 | output=$firstobj\"$file_list_spec$func_to_tool_file_result\" | |
7498 | 8350 | else |
7499 | 8351 | if test -n "$save_libobjs"; then |
7500 | 8352 | func_verbose "creating reloadable object files..." |
7545 | 8397 | if test -n "$last_robj"; then |
7546 | 8398 | eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\" |
7547 | 8399 | fi |
7548 | delfiles="$delfiles $output" | |
8400 | func_append delfiles " $output" | |
7549 | 8401 | |
7550 | 8402 | else |
7551 | 8403 | output= |
7579 | 8431 | lt_exit=$? |
7580 | 8432 | |
7581 | 8433 | # Restore the uninstalled library and exit |
7582 | if test "$mode" = relink; then | |
8434 | if test "$opt_mode" = relink; then | |
7583 | 8435 | ( cd "$output_objdir" && \ |
7584 | 8436 | $RM "${realname}T" && \ |
7585 | 8437 | $MV "${realname}U" "$realname" ) |
7612 | 8464 | # global variables. join(1) would be nice here, but unfortunately |
7613 | 8465 | # isn't a blessed tool. |
7614 | 8466 | $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter |
7615 | delfiles="$delfiles $export_symbols $output_objdir/$libname.filter" | |
8467 | func_append delfiles " $export_symbols $output_objdir/$libname.filter" | |
7616 | 8468 | export_symbols=$output_objdir/$libname.def |
7617 | 8469 | $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols |
7618 | 8470 | fi |
7653 | 8505 | # Add any objects from preloaded convenience libraries |
7654 | 8506 | if test -n "$dlprefiles"; then |
7655 | 8507 | gentop="$output_objdir/${outputname}x" |
7656 | generated="$generated $gentop" | |
8508 | func_append generated " $gentop" | |
7657 | 8509 | |
7658 | 8510 | func_extract_archives $gentop $dlprefiles |
7659 | libobjs="$libobjs $func_extract_archives_result" | |
8511 | func_append libobjs " $func_extract_archives_result" | |
7660 | 8512 | test "X$libobjs" = "X " && libobjs= |
7661 | 8513 | fi |
7662 | 8514 | |
7672 | 8524 | lt_exit=$? |
7673 | 8525 | |
7674 | 8526 | # Restore the uninstalled library and exit |
7675 | if test "$mode" = relink; then | |
8527 | if test "$opt_mode" = relink; then | |
7676 | 8528 | ( cd "$output_objdir" && \ |
7677 | 8529 | $RM "${realname}T" && \ |
7678 | 8530 | $MV "${realname}U" "$realname" ) |
7684 | 8536 | IFS="$save_ifs" |
7685 | 8537 | |
7686 | 8538 | # Restore the uninstalled library and exit |
7687 | if test "$mode" = relink; then | |
8539 | if test "$opt_mode" = relink; then | |
7688 | 8540 | $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? |
7689 | 8541 | |
7690 | 8542 | if test -n "$convenience"; then |
7768 | 8620 | reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` |
7769 | 8621 | else |
7770 | 8622 | gentop="$output_objdir/${obj}x" |
7771 | generated="$generated $gentop" | |
8623 | func_append generated " $gentop" | |
7772 | 8624 | |
7773 | 8625 | func_extract_archives $gentop $convenience |
7774 | 8626 | reload_conv_objs="$reload_objs $func_extract_archives_result" |
7775 | 8627 | fi |
7776 | 8628 | fi |
8629 | ||
8630 | # If we're not building shared, we need to use non_pic_objs | |
8631 | test "$build_libtool_libs" != yes && libobjs="$non_pic_objects" | |
7777 | 8632 | |
7778 | 8633 | # Create the old-style object. |
7779 | 8634 | reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test |
7848 | 8703 | if test "$tagname" = CXX ; then |
7849 | 8704 | case ${MACOSX_DEPLOYMENT_TARGET-10.0} in |
7850 | 8705 | 10.[0123]) |
7851 | compile_command="$compile_command ${wl}-bind_at_load" | |
7852 | finalize_command="$finalize_command ${wl}-bind_at_load" | |
8706 | func_append compile_command " ${wl}-bind_at_load" | |
8707 | func_append finalize_command " ${wl}-bind_at_load" | |
7853 | 8708 | ;; |
7854 | 8709 | esac |
7855 | 8710 | fi |
7869 | 8724 | *) |
7870 | 8725 | case " $compile_deplibs " in |
7871 | 8726 | *" -L$path/$objdir "*) |
7872 | new_libs="$new_libs -L$path/$objdir" ;; | |
8727 | func_append new_libs " -L$path/$objdir" ;; | |
7873 | 8728 | esac |
7874 | 8729 | ;; |
7875 | 8730 | esac |
7879 | 8734 | -L*) |
7880 | 8735 | case " $new_libs " in |
7881 | 8736 | *" $deplib "*) ;; |
7882 | *) new_libs="$new_libs $deplib" ;; | |
8737 | *) func_append new_libs " $deplib" ;; | |
7883 | 8738 | esac |
7884 | 8739 | ;; |
7885 | *) new_libs="$new_libs $deplib" ;; | |
8740 | *) func_append new_libs " $deplib" ;; | |
7886 | 8741 | esac |
7887 | 8742 | done |
7888 | 8743 | compile_deplibs="$new_libs" |
7889 | 8744 | |
7890 | 8745 | |
7891 | compile_command="$compile_command $compile_deplibs" | |
7892 | finalize_command="$finalize_command $finalize_deplibs" | |
8746 | func_append compile_command " $compile_deplibs" | |
8747 | func_append finalize_command " $finalize_deplibs" | |
7893 | 8748 | |
7894 | 8749 | if test -n "$rpath$xrpath"; then |
7895 | 8750 | # If the user specified any rpath flags, then add them. |
7897 | 8752 | # This is the magic to use -rpath. |
7898 | 8753 | case "$finalize_rpath " in |
7899 | 8754 | *" $libdir "*) ;; |
7900 | *) finalize_rpath="$finalize_rpath $libdir" ;; | |
8755 | *) func_append finalize_rpath " $libdir" ;; | |
7901 | 8756 | esac |
7902 | 8757 | done |
7903 | 8758 | fi |
7916 | 8771 | *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) |
7917 | 8772 | ;; |
7918 | 8773 | *) |
7919 | hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" | |
8774 | func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" | |
7920 | 8775 | ;; |
7921 | 8776 | esac |
7922 | 8777 | fi |
7923 | 8778 | else |
7924 | 8779 | eval flag=\"$hardcode_libdir_flag_spec\" |
7925 | rpath="$rpath $flag" | |
8780 | func_append rpath " $flag" | |
7926 | 8781 | fi |
7927 | 8782 | elif test -n "$runpath_var"; then |
7928 | 8783 | case "$perm_rpath " in |
7929 | 8784 | *" $libdir "*) ;; |
7930 | *) perm_rpath="$perm_rpath $libdir" ;; | |
8785 | *) func_append perm_rpath " $libdir" ;; | |
7931 | 8786 | esac |
7932 | 8787 | fi |
7933 | 8788 | case $host in |
7936 | 8791 | case :$dllsearchpath: in |
7937 | 8792 | *":$libdir:"*) ;; |
7938 | 8793 | ::) dllsearchpath=$libdir;; |
7939 | *) dllsearchpath="$dllsearchpath:$libdir";; | |
8794 | *) func_append dllsearchpath ":$libdir";; | |
7940 | 8795 | esac |
7941 | 8796 | case :$dllsearchpath: in |
7942 | 8797 | *":$testbindir:"*) ;; |
7943 | 8798 | ::) dllsearchpath=$testbindir;; |
7944 | *) dllsearchpath="$dllsearchpath:$testbindir";; | |
8799 | *) func_append dllsearchpath ":$testbindir";; | |
7945 | 8800 | esac |
7946 | 8801 | ;; |
7947 | 8802 | esac |
7967 | 8822 | *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) |
7968 | 8823 | ;; |
7969 | 8824 | *) |
7970 | hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" | |
8825 | func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" | |
7971 | 8826 | ;; |
7972 | 8827 | esac |
7973 | 8828 | fi |
7974 | 8829 | else |
7975 | 8830 | eval flag=\"$hardcode_libdir_flag_spec\" |
7976 | rpath="$rpath $flag" | |
8831 | func_append rpath " $flag" | |
7977 | 8832 | fi |
7978 | 8833 | elif test -n "$runpath_var"; then |
7979 | 8834 | case "$finalize_perm_rpath " in |
7980 | 8835 | *" $libdir "*) ;; |
7981 | *) finalize_perm_rpath="$finalize_perm_rpath $libdir" ;; | |
8836 | *) func_append finalize_perm_rpath " $libdir" ;; | |
7982 | 8837 | esac |
7983 | 8838 | fi |
7984 | 8839 | done |
8029 | 8884 | exit_status=0 |
8030 | 8885 | func_show_eval "$link_command" 'exit_status=$?' |
8031 | 8886 | |
8887 | if test -n "$postlink_cmds"; then | |
8888 | func_to_tool_file "$output" | |
8889 | postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` | |
8890 | func_execute_cmds "$postlink_cmds" 'exit $?' | |
8891 | fi | |
8892 | ||
8032 | 8893 | # Delete the generated files. |
8033 | 8894 | if test -f "$output_objdir/${outputname}S.${objext}"; then |
8034 | 8895 | func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"' |
8051 | 8912 | # We should set the runpath_var. |
8052 | 8913 | rpath= |
8053 | 8914 | for dir in $perm_rpath; do |
8054 | rpath="$rpath$dir:" | |
8915 | func_append rpath "$dir:" | |
8055 | 8916 | done |
8056 | 8917 | compile_var="$runpath_var=\"$rpath\$$runpath_var\" " |
8057 | 8918 | fi |
8059 | 8920 | # We should set the runpath_var. |
8060 | 8921 | rpath= |
8061 | 8922 | for dir in $finalize_perm_rpath; do |
8062 | rpath="$rpath$dir:" | |
8923 | func_append rpath "$dir:" | |
8063 | 8924 | done |
8064 | 8925 | finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " |
8065 | 8926 | fi |
8074 | 8935 | $opt_dry_run || $RM $output |
8075 | 8936 | # Link the executable and exit |
8076 | 8937 | func_show_eval "$link_command" 'exit $?' |
8938 | ||
8939 | if test -n "$postlink_cmds"; then | |
8940 | func_to_tool_file "$output" | |
8941 | postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` | |
8942 | func_execute_cmds "$postlink_cmds" 'exit $?' | |
8943 | fi | |
8944 | ||
8077 | 8945 | exit $EXIT_SUCCESS |
8078 | 8946 | fi |
8079 | 8947 | |
8106 | 8974 | $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname |
8107 | 8975 | |
8108 | 8976 | func_show_eval "$link_command" 'exit $?' |
8977 | ||
8978 | if test -n "$postlink_cmds"; then | |
8979 | func_to_tool_file "$output_objdir/$outputname" | |
8980 | postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` | |
8981 | func_execute_cmds "$postlink_cmds" 'exit $?' | |
8982 | fi | |
8109 | 8983 | |
8110 | 8984 | # Now create the wrapper script. |
8111 | 8985 | func_verbose "creating $output" |
8204 | 9078 | else |
8205 | 9079 | oldobjs="$old_deplibs $non_pic_objects" |
8206 | 9080 | if test "$preload" = yes && test -f "$symfileobj"; then |
8207 | oldobjs="$oldobjs $symfileobj" | |
9081 | func_append oldobjs " $symfileobj" | |
8208 | 9082 | fi |
8209 | 9083 | fi |
8210 | 9084 | addlibs="$old_convenience" |
8212 | 9086 | |
8213 | 9087 | if test -n "$addlibs"; then |
8214 | 9088 | gentop="$output_objdir/${outputname}x" |
8215 | generated="$generated $gentop" | |
9089 | func_append generated " $gentop" | |
8216 | 9090 | |
8217 | 9091 | func_extract_archives $gentop $addlibs |
8218 | oldobjs="$oldobjs $func_extract_archives_result" | |
9092 | func_append oldobjs " $func_extract_archives_result" | |
8219 | 9093 | fi |
8220 | 9094 | |
8221 | 9095 | # Do each command in the archive commands. |
8226 | 9100 | # Add any objects from preloaded convenience libraries |
8227 | 9101 | if test -n "$dlprefiles"; then |
8228 | 9102 | gentop="$output_objdir/${outputname}x" |
8229 | generated="$generated $gentop" | |
9103 | func_append generated " $gentop" | |
8230 | 9104 | |
8231 | 9105 | func_extract_archives $gentop $dlprefiles |
8232 | oldobjs="$oldobjs $func_extract_archives_result" | |
9106 | func_append oldobjs " $func_extract_archives_result" | |
8233 | 9107 | fi |
8234 | 9108 | |
8235 | 9109 | # POSIX demands no paths to be encoded in archives. We have |
8247 | 9121 | else |
8248 | 9122 | echo "copying selected object files to avoid basename conflicts..." |
8249 | 9123 | gentop="$output_objdir/${outputname}x" |
8250 | generated="$generated $gentop" | |
9124 | func_append generated " $gentop" | |
8251 | 9125 | func_mkdir_p "$gentop" |
8252 | 9126 | save_oldobjs=$oldobjs |
8253 | 9127 | oldobjs= |
8271 | 9145 | esac |
8272 | 9146 | done |
8273 | 9147 | func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" |
8274 | oldobjs="$oldobjs $gentop/$newobj" | |
9148 | func_append oldobjs " $gentop/$newobj" | |
8275 | 9149 | ;; |
8276 | *) oldobjs="$oldobjs $obj" ;; | |
9150 | *) func_append oldobjs " $obj" ;; | |
8277 | 9151 | esac |
8278 | 9152 | done |
8279 | 9153 | fi |
8282 | 9156 | func_len " $cmds" |
8283 | 9157 | len=$func_len_result |
8284 | 9158 | if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then |
9159 | cmds=$old_archive_cmds | |
9160 | elif test -n "$archiver_list_spec"; then | |
9161 | func_verbose "using command file archive linking..." | |
9162 | for obj in $oldobjs | |
9163 | do | |
9164 | func_to_tool_file "$obj" | |
9165 | $ECHO "$func_to_tool_file_result" | |
9166 | done > $output_objdir/$libname.libcmd | |
9167 | func_to_tool_file "$output_objdir/$libname.libcmd" | |
9168 | oldobjs=" $archiver_list_spec$func_to_tool_file_result" | |
8285 | 9169 | cmds=$old_archive_cmds |
8286 | 9170 | else |
8287 | 9171 | # the command line is too long to link in one step, link in parts |
8379 | 9263 | eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` |
8380 | 9264 | test -z "$libdir" && \ |
8381 | 9265 | func_fatal_error "\`$deplib' is not a valid libtool archive" |
8382 | newdependency_libs="$newdependency_libs $libdir/$name" | |
9266 | func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" | |
8383 | 9267 | ;; |
8384 | *) newdependency_libs="$newdependency_libs $deplib" ;; | |
9268 | -L*) | |
9269 | func_stripname -L '' "$deplib" | |
9270 | func_replace_sysroot "$func_stripname_result" | |
9271 | func_append newdependency_libs " -L$func_replace_sysroot_result" | |
9272 | ;; | |
9273 | -R*) | |
9274 | func_stripname -R '' "$deplib" | |
9275 | func_replace_sysroot "$func_stripname_result" | |
9276 | func_append newdependency_libs " -R$func_replace_sysroot_result" | |
9277 | ;; | |
9278 | *) func_append newdependency_libs " $deplib" ;; | |
8385 | 9279 | esac |
8386 | 9280 | done |
8387 | 9281 | dependency_libs="$newdependency_libs" |
8395 | 9289 | eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` |
8396 | 9290 | test -z "$libdir" && \ |
8397 | 9291 | func_fatal_error "\`$lib' is not a valid libtool archive" |
8398 | newdlfiles="$newdlfiles $libdir/$name" | |
9292 | func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" | |
8399 | 9293 | ;; |
8400 | *) newdlfiles="$newdlfiles $lib" ;; | |
9294 | *) func_append newdlfiles " $lib" ;; | |
8401 | 9295 | esac |
8402 | 9296 | done |
8403 | 9297 | dlfiles="$newdlfiles" |
8414 | 9308 | eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` |
8415 | 9309 | test -z "$libdir" && \ |
8416 | 9310 | func_fatal_error "\`$lib' is not a valid libtool archive" |
8417 | newdlprefiles="$newdlprefiles $libdir/$name" | |
9311 | func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" | |
8418 | 9312 | ;; |
8419 | 9313 | esac |
8420 | 9314 | done |
8426 | 9320 | [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; |
8427 | 9321 | *) abs=`pwd`"/$lib" ;; |
8428 | 9322 | esac |
8429 | newdlfiles="$newdlfiles $abs" | |
9323 | func_append newdlfiles " $abs" | |
8430 | 9324 | done |
8431 | 9325 | dlfiles="$newdlfiles" |
8432 | 9326 | newdlprefiles= |
8435 | 9329 | [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; |
8436 | 9330 | *) abs=`pwd`"/$lib" ;; |
8437 | 9331 | esac |
8438 | newdlprefiles="$newdlprefiles $abs" | |
9332 | func_append newdlprefiles " $abs" | |
8439 | 9333 | done |
8440 | 9334 | dlprefiles="$newdlprefiles" |
8441 | 9335 | fi |
8520 | 9414 | exit $EXIT_SUCCESS |
8521 | 9415 | } |
8522 | 9416 | |
8523 | { test "$mode" = link || test "$mode" = relink; } && | |
9417 | { test "$opt_mode" = link || test "$opt_mode" = relink; } && | |
8524 | 9418 | func_mode_link ${1+"$@"} |
8525 | 9419 | |
8526 | 9420 | |
8540 | 9434 | for arg |
8541 | 9435 | do |
8542 | 9436 | case $arg in |
8543 | -f) RM="$RM $arg"; rmforce=yes ;; | |
8544 | -*) RM="$RM $arg" ;; | |
8545 | *) files="$files $arg" ;; | |
9437 | -f) func_append RM " $arg"; rmforce=yes ;; | |
9438 | -*) func_append RM " $arg" ;; | |
9439 | *) func_append files " $arg" ;; | |
8546 | 9440 | esac |
8547 | 9441 | done |
8548 | 9442 | |
8551 | 9445 | |
8552 | 9446 | rmdirs= |
8553 | 9447 | |
8554 | origobjdir="$objdir" | |
8555 | 9448 | for file in $files; do |
8556 | 9449 | func_dirname "$file" "" "." |
8557 | 9450 | dir="$func_dirname_result" |
8558 | 9451 | if test "X$dir" = X.; then |
8559 | objdir="$origobjdir" | |
9452 | odir="$objdir" | |
8560 | 9453 | else |
8561 | objdir="$dir/$origobjdir" | |
9454 | odir="$dir/$objdir" | |
8562 | 9455 | fi |
8563 | 9456 | func_basename "$file" |
8564 | 9457 | name="$func_basename_result" |
8565 | test "$mode" = uninstall && objdir="$dir" | |
8566 | ||
8567 | # Remember objdir for removal later, being careful to avoid duplicates | |
8568 | if test "$mode" = clean; then | |
9458 | test "$opt_mode" = uninstall && odir="$dir" | |
9459 | ||
9460 | # Remember odir for removal later, being careful to avoid duplicates | |
9461 | if test "$opt_mode" = clean; then | |
8569 | 9462 | case " $rmdirs " in |
8570 | *" $objdir "*) ;; | |
8571 | *) rmdirs="$rmdirs $objdir" ;; | |
9463 | *" $odir "*) ;; | |
9464 | *) func_append rmdirs " $odir" ;; | |
8572 | 9465 | esac |
8573 | 9466 | fi |
8574 | 9467 | |
8594 | 9487 | |
8595 | 9488 | # Delete the libtool libraries and symlinks. |
8596 | 9489 | for n in $library_names; do |
8597 | rmfiles="$rmfiles $objdir/$n" | |
9490 | func_append rmfiles " $odir/$n" | |
8598 | 9491 | done |
8599 | test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" | |
8600 | ||
8601 | case "$mode" in | |
9492 | test -n "$old_library" && func_append rmfiles " $odir/$old_library" | |
9493 | ||
9494 | case "$opt_mode" in | |
8602 | 9495 | clean) |
8603 | case " $library_names " in | |
8604 | # " " in the beginning catches empty $dlname | |
9496 | case " $library_names " in | |
8605 | 9497 | *" $dlname "*) ;; |
8606 | *) rmfiles="$rmfiles $objdir/$dlname" ;; | |
9498 | *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; | |
8607 | 9499 | esac |
8608 | test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" | |
9500 | test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" | |
8609 | 9501 | ;; |
8610 | 9502 | uninstall) |
8611 | 9503 | if test -n "$library_names"; then |
8633 | 9525 | # Add PIC object to the list of files to remove. |
8634 | 9526 | if test -n "$pic_object" && |
8635 | 9527 | test "$pic_object" != none; then |
8636 | rmfiles="$rmfiles $dir/$pic_object" | |
9528 | func_append rmfiles " $dir/$pic_object" | |
8637 | 9529 | fi |
8638 | 9530 | |
8639 | 9531 | # Add non-PIC object to the list of files to remove. |
8640 | 9532 | if test -n "$non_pic_object" && |
8641 | 9533 | test "$non_pic_object" != none; then |
8642 | rmfiles="$rmfiles $dir/$non_pic_object" | |
9534 | func_append rmfiles " $dir/$non_pic_object" | |
8643 | 9535 | fi |
8644 | 9536 | fi |
8645 | 9537 | ;; |
8646 | 9538 | |
8647 | 9539 | *) |
8648 | if test "$mode" = clean ; then | |
9540 | if test "$opt_mode" = clean ; then | |
8649 | 9541 | noexename=$name |
8650 | 9542 | case $file in |
8651 | 9543 | *.exe) |
8655 | 9547 | noexename=$func_stripname_result |
8656 | 9548 | # $file with .exe has already been added to rmfiles, |
8657 | 9549 | # add $file without .exe |
8658 | rmfiles="$rmfiles $file" | |
9550 | func_append rmfiles " $file" | |
8659 | 9551 | ;; |
8660 | 9552 | esac |
8661 | 9553 | # Do a test to see if this is a libtool program. |
8664 | 9556 | func_ltwrapper_scriptname "$file" |
8665 | 9557 | relink_command= |
8666 | 9558 | func_source $func_ltwrapper_scriptname_result |
8667 | rmfiles="$rmfiles $func_ltwrapper_scriptname_result" | |
9559 | func_append rmfiles " $func_ltwrapper_scriptname_result" | |
8668 | 9560 | else |
8669 | 9561 | relink_command= |
8670 | 9562 | func_source $dir/$noexename |
8672 | 9564 | |
8673 | 9565 | # note $name still contains .exe if it was in $file originally |
8674 | 9566 | # as does the version of $file that was added into $rmfiles |
8675 | rmfiles="$rmfiles $objdir/$name $objdir/${name}S.${objext}" | |
9567 | func_append rmfiles " $odir/$name $odir/${name}S.${objext}" | |
8676 | 9568 | if test "$fast_install" = yes && test -n "$relink_command"; then |
8677 | rmfiles="$rmfiles $objdir/lt-$name" | |
9569 | func_append rmfiles " $odir/lt-$name" | |
8678 | 9570 | fi |
8679 | 9571 | if test "X$noexename" != "X$name" ; then |
8680 | rmfiles="$rmfiles $objdir/lt-${noexename}.c" | |
9572 | func_append rmfiles " $odir/lt-${noexename}.c" | |
8681 | 9573 | fi |
8682 | 9574 | fi |
8683 | 9575 | fi |
8685 | 9577 | esac |
8686 | 9578 | func_show_eval "$RM $rmfiles" 'exit_status=1' |
8687 | 9579 | done |
8688 | objdir="$origobjdir" | |
8689 | 9580 | |
8690 | 9581 | # Try to remove the ${objdir}s in the directories where we deleted files |
8691 | 9582 | for dir in $rmdirs; do |
8697 | 9588 | exit $exit_status |
8698 | 9589 | } |
8699 | 9590 | |
8700 | { test "$mode" = uninstall || test "$mode" = clean; } && | |
9591 | { test "$opt_mode" = uninstall || test "$opt_mode" = clean; } && | |
8701 | 9592 | func_mode_uninstall ${1+"$@"} |
8702 | 9593 | |
8703 | test -z "$mode" && { | |
9594 | test -z "$opt_mode" && { | |
8704 | 9595 | help="$generic_help" |
8705 | 9596 | func_fatal_help "you must specify a MODE" |
8706 | 9597 | } |
8707 | 9598 | |
8708 | 9599 | test -z "$exec_cmd" && \ |
8709 | func_fatal_help "invalid operation mode \`$mode'" | |
9600 | func_fatal_help "invalid operation mode \`$opt_mode'" | |
8710 | 9601 | |
8711 | 9602 | if test -n "$exec_cmd"; then |
8712 | 9603 | eval exec "$exec_cmd" |
167 | 167 | dnl |
168 | 168 | m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
169 | 169 | m4_require([_LT_CHECK_SHELL_FEATURES])dnl |
170 | m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl | |
170 | 171 | m4_require([_LT_CMD_RELOAD])dnl |
171 | 172 | m4_require([_LT_CHECK_MAGIC_METHOD])dnl |
173 | m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl | |
172 | 174 | m4_require([_LT_CMD_OLD_ARCHIVE])dnl |
173 | 175 | m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl |
176 | m4_require([_LT_WITH_SYSROOT])dnl | |
174 | 177 | |
175 | 178 | _LT_CONFIG_LIBTOOL_INIT([ |
176 | 179 | # See if we are running on zsh, and set the options which allow our |
747 | 750 | # if finds mixed CR/LF and LF-only lines. Since sed operates in |
748 | 751 | # text mode, it properly converts lines to CR/LF. This bash problem |
749 | 752 | # is reportedly fixed, but why not run on old versions too? |
750 | sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \ | |
751 | || (rm -f "$cfgfile"; exit 1) | |
752 | ||
753 | _LT_PROG_XSI_SHELLFNS | |
754 | ||
755 | sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \ | |
756 | || (rm -f "$cfgfile"; exit 1) | |
757 | ||
758 | mv -f "$cfgfile" "$ofile" || | |
753 | sed '$q' "$ltmain" >> "$cfgfile" \ | |
754 | || (rm -f "$cfgfile"; exit 1) | |
755 | ||
756 | _LT_PROG_REPLACE_SHELLFNS | |
757 | ||
758 | mv -f "$cfgfile" "$ofile" || | |
759 | 759 | (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") |
760 | 760 | chmod +x "$ofile" |
761 | 761 | ], |
1072 | 1072 | fi |
1073 | 1073 | ]) |
1074 | 1074 | |
1075 | # _LT_SYS_MODULE_PATH_AIX | |
1076 | # ----------------------- | |
1075 | # _LT_SYS_MODULE_PATH_AIX([TAGNAME]) | |
1076 | # ---------------------------------- | |
1077 | 1077 | # Links a minimal program and checks the executable |
1078 | 1078 | # for the system default hardcoded library path. In most cases, |
1079 | 1079 | # this is /usr/lib:/lib, but when the MPI compilers are used |
1080 | 1080 | # the location of the communication and MPI libs are included too. |
1081 | 1081 | # If we don't find anything, use the default library path according |
1082 | 1082 | # to the aix ld manual. |
1083 | # Store the results from the different compilers for each TAGNAME. | |
1084 | # Allow to override them for all tags through lt_cv_aix_libpath. | |
1083 | 1085 | m4_defun([_LT_SYS_MODULE_PATH_AIX], |
1084 | 1086 | [m4_require([_LT_DECL_SED])dnl |
1085 | AC_LINK_IFELSE(AC_LANG_PROGRAM,[ | |
1086 | lt_aix_libpath_sed=' | |
1087 | /Import File Strings/,/^$/ { | |
1088 | /^0/ { | |
1089 | s/^0 *\(.*\)$/\1/ | |
1090 | p | |
1091 | } | |
1092 | }' | |
1093 | aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
1094 | # Check for a 64-bit object if we didn't find anything. | |
1095 | if test -z "$aix_libpath"; then | |
1096 | aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
1097 | fi],[]) | |
1098 | if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi | |
1087 | if test "${lt_cv_aix_libpath+set}" = set; then | |
1088 | aix_libpath=$lt_cv_aix_libpath | |
1089 | else | |
1090 | AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], | |
1091 | [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ | |
1092 | lt_aix_libpath_sed='[ | |
1093 | /Import File Strings/,/^$/ { | |
1094 | /^0/ { | |
1095 | s/^0 *\([^ ]*\) *$/\1/ | |
1096 | p | |
1097 | } | |
1098 | }]' | |
1099 | _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
1100 | # Check for a 64-bit object if we didn't find anything. | |
1101 | if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then | |
1102 | _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
1103 | fi],[]) | |
1104 | if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then | |
1105 | _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib" | |
1106 | fi | |
1107 | ]) | |
1108 | aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) | |
1109 | fi | |
1099 | 1110 | ])# _LT_SYS_MODULE_PATH_AIX |
1100 | 1111 | |
1101 | 1112 | |
1120 | 1131 | |
1121 | 1132 | AC_MSG_CHECKING([how to print strings]) |
1122 | 1133 | # Test print first, because it will be a builtin if present. |
1123 | if test "X`print -r -- -n 2>/dev/null`" = X-n && \ | |
1134 | if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ | |
1124 | 1135 | test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then |
1125 | 1136 | ECHO='print -r --' |
1126 | 1137 | elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then |
1163 | 1174 | _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) |
1164 | 1175 | ])# _LT_PROG_ECHO_BACKSLASH |
1165 | 1176 | |
1177 | ||
1178 | # _LT_WITH_SYSROOT | |
1179 | # ---------------- | |
1180 | AC_DEFUN([_LT_WITH_SYSROOT], | |
1181 | [AC_MSG_CHECKING([for sysroot]) | |
1182 | AC_ARG_WITH([sysroot], | |
1183 | [ --with-sysroot[=DIR] Search for dependent libraries within DIR | |
1184 | (or the compiler's sysroot if not specified).], | |
1185 | [], [with_sysroot=no]) | |
1186 | ||
1187 | dnl lt_sysroot will always be passed unquoted. We quote it here | |
1188 | dnl in case the user passed a directory name. | |
1189 | lt_sysroot= | |
1190 | case ${with_sysroot} in #( | |
1191 | yes) | |
1192 | if test "$GCC" = yes; then | |
1193 | lt_sysroot=`$CC --print-sysroot 2>/dev/null` | |
1194 | fi | |
1195 | ;; #( | |
1196 | /*) | |
1197 | lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` | |
1198 | ;; #( | |
1199 | no|'') | |
1200 | ;; #( | |
1201 | *) | |
1202 | AC_MSG_RESULT([${with_sysroot}]) | |
1203 | AC_MSG_ERROR([The sysroot must be an absolute path.]) | |
1204 | ;; | |
1205 | esac | |
1206 | ||
1207 | AC_MSG_RESULT([${lt_sysroot:-no}]) | |
1208 | _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl | |
1209 | [dependent libraries, and in which our libraries should be installed.])]) | |
1166 | 1210 | |
1167 | 1211 | # _LT_ENABLE_LOCK |
1168 | 1212 | # --------------- |
1310 | 1354 | ])# _LT_ENABLE_LOCK |
1311 | 1355 | |
1312 | 1356 | |
1357 | # _LT_PROG_AR | |
1358 | # ----------- | |
1359 | m4_defun([_LT_PROG_AR], | |
1360 | [AC_CHECK_TOOLS(AR, [ar], false) | |
1361 | : ${AR=ar} | |
1362 | : ${AR_FLAGS=cru} | |
1363 | _LT_DECL([], [AR], [1], [The archiver]) | |
1364 | _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) | |
1365 | ||
1366 | AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], | |
1367 | [lt_cv_ar_at_file=no | |
1368 | AC_COMPILE_IFELSE([AC_LANG_PROGRAM], | |
1369 | [echo conftest.$ac_objext > conftest.lst | |
1370 | lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' | |
1371 | AC_TRY_EVAL([lt_ar_try]) | |
1372 | if test "$ac_status" -eq 0; then | |
1373 | # Ensure the archiver fails upon bogus file names. | |
1374 | rm -f conftest.$ac_objext libconftest.a | |
1375 | AC_TRY_EVAL([lt_ar_try]) | |
1376 | if test "$ac_status" -ne 0; then | |
1377 | lt_cv_ar_at_file=@ | |
1378 | fi | |
1379 | fi | |
1380 | rm -f conftest.* libconftest.a | |
1381 | ]) | |
1382 | ]) | |
1383 | ||
1384 | if test "x$lt_cv_ar_at_file" = xno; then | |
1385 | archiver_list_spec= | |
1386 | else | |
1387 | archiver_list_spec=$lt_cv_ar_at_file | |
1388 | fi | |
1389 | _LT_DECL([], [archiver_list_spec], [1], | |
1390 | [How to feed a file listing to the archiver]) | |
1391 | ])# _LT_PROG_AR | |
1392 | ||
1393 | ||
1313 | 1394 | # _LT_CMD_OLD_ARCHIVE |
1314 | 1395 | # ------------------- |
1315 | 1396 | m4_defun([_LT_CMD_OLD_ARCHIVE], |
1316 | [AC_CHECK_TOOL(AR, ar, false) | |
1317 | test -z "$AR" && AR=ar | |
1318 | test -z "$AR_FLAGS" && AR_FLAGS=cru | |
1319 | _LT_DECL([], [AR], [1], [The archiver]) | |
1320 | _LT_DECL([], [AR_FLAGS], [1]) | |
1397 | [_LT_PROG_AR | |
1321 | 1398 | |
1322 | 1399 | AC_CHECK_TOOL(STRIP, strip, :) |
1323 | 1400 | test -z "$STRIP" && STRIP=: |
1657 | 1734 | /* When -fvisbility=hidden is used, assume the code has been annotated |
1658 | 1735 | correspondingly for the symbols needed. */ |
1659 | 1736 | #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) |
1660 | void fnord () __attribute__((visibility("default"))); | |
1737 | int fnord () __attribute__((visibility("default"))); | |
1661 | 1738 | #endif |
1662 | 1739 | |
1663 | void fnord () { int i=42; } | |
1740 | int fnord () { return 42; } | |
1664 | 1741 | int main () |
1665 | 1742 | { |
1666 | 1743 | void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); |
2200 | 2277 | need_version=no |
2201 | 2278 | need_lib_prefix=no |
2202 | 2279 | |
2203 | case $GCC,$host_os in | |
2204 | yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) | |
2280 | case $GCC,$cc_basename in | |
2281 | yes,*) | |
2282 | # gcc | |
2205 | 2283 | library_names_spec='$libname.dll.a' |
2206 | 2284 | # DLL is installed to $(libdir)/../bin by postinstall_cmds |
2207 | 2285 | postinstall_cmds='base_file=`basename \${file}`~ |
2234 | 2312 | library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' |
2235 | 2313 | ;; |
2236 | 2314 | esac |
2315 | dynamic_linker='Win32 ld.exe' | |
2237 | 2316 | ;; |
2238 | 2317 | |
2318 | *,cl*) | |
2319 | # Native MSVC | |
2320 | libname_spec='$name' | |
2321 | soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' | |
2322 | library_names_spec='${libname}.dll.lib' | |
2323 | ||
2324 | case $build_os in | |
2325 | mingw*) | |
2326 | sys_lib_search_path_spec= | |
2327 | lt_save_ifs=$IFS | |
2328 | IFS=';' | |
2329 | for lt_path in $LIB | |
2330 | do | |
2331 | IFS=$lt_save_ifs | |
2332 | # Let DOS variable expansion print the short 8.3 style file name. | |
2333 | lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` | |
2334 | sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" | |
2335 | done | |
2336 | IFS=$lt_save_ifs | |
2337 | # Convert to MSYS style. | |
2338 | sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` | |
2339 | ;; | |
2340 | cygwin*) | |
2341 | # Convert to unix form, then to dos form, then back to unix form | |
2342 | # but this time dos style (no spaces!) so that the unix form looks | |
2343 | # like /cygdrive/c/PROGRA~1:/cygdr... | |
2344 | sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` | |
2345 | sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` | |
2346 | sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` | |
2347 | ;; | |
2348 | *) | |
2349 | sys_lib_search_path_spec="$LIB" | |
2350 | if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then | |
2351 | # It is most probably a Windows format PATH. | |
2352 | sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` | |
2353 | else | |
2354 | sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` | |
2355 | fi | |
2356 | # FIXME: find the short name or the path components, as spaces are | |
2357 | # common. (e.g. "Program Files" -> "PROGRA~1") | |
2358 | ;; | |
2359 | esac | |
2360 | ||
2361 | # DLL is installed to $(libdir)/../bin by postinstall_cmds | |
2362 | postinstall_cmds='base_file=`basename \${file}`~ | |
2363 | dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ | |
2364 | dldir=$destdir/`dirname \$dlpath`~ | |
2365 | test -d \$dldir || mkdir -p \$dldir~ | |
2366 | $install_prog $dir/$dlname \$dldir/$dlname' | |
2367 | postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ | |
2368 | dlpath=$dir/\$dldll~ | |
2369 | $RM \$dlpath' | |
2370 | shlibpath_overrides_runpath=yes | |
2371 | dynamic_linker='Win32 link.exe' | |
2372 | ;; | |
2373 | ||
2239 | 2374 | *) |
2375 | # Assume MSVC wrapper | |
2240 | 2376 | library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' |
2377 | dynamic_linker='Win32 ld.exe' | |
2241 | 2378 | ;; |
2242 | 2379 | esac |
2243 | dynamic_linker='Win32 ld.exe' | |
2244 | 2380 | # FIXME: first we should search . and the directory the executable is in |
2245 | 2381 | shlibpath_var=PATH |
2246 | 2382 | ;; |
2948 | 3084 | esac |
2949 | 3085 | reload_cmds='$LD$reload_flag -o $output$reload_objs' |
2950 | 3086 | case $host_os in |
3087 | cygwin* | mingw* | pw32* | cegcc*) | |
3088 | if test "$GCC" != yes; then | |
3089 | reload_cmds=false | |
3090 | fi | |
3091 | ;; | |
2951 | 3092 | darwin*) |
2952 | 3093 | if test "$GCC" = yes; then |
2953 | 3094 | reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' |
3166 | 3307 | ;; |
3167 | 3308 | esac |
3168 | 3309 | ]) |
3310 | ||
3311 | file_magic_glob= | |
3312 | want_nocaseglob=no | |
3313 | if test "$build" = "$host"; then | |
3314 | case $host_os in | |
3315 | mingw* | pw32*) | |
3316 | if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then | |
3317 | want_nocaseglob=yes | |
3318 | else | |
3319 | file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` | |
3320 | fi | |
3321 | ;; | |
3322 | esac | |
3323 | fi | |
3324 | ||
3169 | 3325 | file_magic_cmd=$lt_cv_file_magic_cmd |
3170 | 3326 | deplibs_check_method=$lt_cv_deplibs_check_method |
3171 | 3327 | test -z "$deplibs_check_method" && deplibs_check_method=unknown |
3173 | 3329 | _LT_DECL([], [deplibs_check_method], [1], |
3174 | 3330 | [Method to check whether dependent libraries are shared objects]) |
3175 | 3331 | _LT_DECL([], [file_magic_cmd], [1], |
3176 | [Command to use when deplibs_check_method == "file_magic"]) | |
3332 | [Command to use when deplibs_check_method = "file_magic"]) | |
3333 | _LT_DECL([], [file_magic_glob], [1], | |
3334 | [How to find potential files when deplibs_check_method = "file_magic"]) | |
3335 | _LT_DECL([], [want_nocaseglob], [1], | |
3336 | [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) | |
3177 | 3337 | ])# _LT_CHECK_MAGIC_METHOD |
3178 | 3338 | |
3179 | 3339 | |
3276 | 3436 | dnl AC_DEFUN([AM_PROG_NM], []) |
3277 | 3437 | dnl AC_DEFUN([AC_PROG_NM], []) |
3278 | 3438 | |
3439 | # _LT_CHECK_SHAREDLIB_FROM_LINKLIB | |
3440 | # -------------------------------- | |
3441 | # how to determine the name of the shared library | |
3442 | # associated with a specific link library. | |
3443 | # -- PORTME fill in with the dynamic library characteristics | |
3444 | m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], | |
3445 | [m4_require([_LT_DECL_EGREP]) | |
3446 | m4_require([_LT_DECL_OBJDUMP]) | |
3447 | m4_require([_LT_DECL_DLLTOOL]) | |
3448 | AC_CACHE_CHECK([how to associate runtime and link libraries], | |
3449 | lt_cv_sharedlib_from_linklib_cmd, | |
3450 | [lt_cv_sharedlib_from_linklib_cmd='unknown' | |
3451 | ||
3452 | case $host_os in | |
3453 | cygwin* | mingw* | pw32* | cegcc*) | |
3454 | # two different shell functions defined in ltmain.sh | |
3455 | # decide which to use based on capabilities of $DLLTOOL | |
3456 | case `$DLLTOOL --help 2>&1` in | |
3457 | *--identify-strict*) | |
3458 | lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib | |
3459 | ;; | |
3460 | *) | |
3461 | lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback | |
3462 | ;; | |
3463 | esac | |
3464 | ;; | |
3465 | *) | |
3466 | # fallback: assume linklib IS sharedlib | |
3467 | lt_cv_sharedlib_from_linklib_cmd="$ECHO" | |
3468 | ;; | |
3469 | esac | |
3470 | ]) | |
3471 | sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd | |
3472 | test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO | |
3473 | ||
3474 | _LT_DECL([], [sharedlib_from_linklib_cmd], [1], | |
3475 | [Command to associate shared and link libraries]) | |
3476 | ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB | |
3477 | ||
3478 | ||
3479 | # _LT_PATH_MANIFEST_TOOL | |
3480 | # ---------------------- | |
3481 | # locate the manifest tool | |
3482 | m4_defun([_LT_PATH_MANIFEST_TOOL], | |
3483 | [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) | |
3484 | test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt | |
3485 | AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], | |
3486 | [lt_cv_path_mainfest_tool=no | |
3487 | echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD | |
3488 | $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out | |
3489 | cat conftest.err >&AS_MESSAGE_LOG_FD | |
3490 | if $GREP 'Manifest Tool' conftest.out > /dev/null; then | |
3491 | lt_cv_path_mainfest_tool=yes | |
3492 | fi | |
3493 | rm -f conftest*]) | |
3494 | if test "x$lt_cv_path_mainfest_tool" != xyes; then | |
3495 | MANIFEST_TOOL=: | |
3496 | fi | |
3497 | _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl | |
3498 | ])# _LT_PATH_MANIFEST_TOOL | |
3499 | ||
3279 | 3500 | |
3280 | 3501 | # LT_LIB_M |
3281 | 3502 | # -------- |
3402 | 3623 | lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" |
3403 | 3624 | |
3404 | 3625 | # Transform an extracted symbol line into symbol name and symbol address |
3405 | lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" | |
3406 | lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'" | |
3626 | lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" | |
3627 | lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'" | |
3407 | 3628 | |
3408 | 3629 | # Handle CRLF in mingw tool chain |
3409 | 3630 | opt_cr= |
3439 | 3660 | else |
3440 | 3661 | lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" |
3441 | 3662 | fi |
3663 | lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" | |
3442 | 3664 | |
3443 | 3665 | # Check to see that the pipe works correctly. |
3444 | 3666 | pipe_works=no |
3472 | 3694 | if $GREP ' nm_test_var$' "$nlist" >/dev/null; then |
3473 | 3695 | if $GREP ' nm_test_func$' "$nlist" >/dev/null; then |
3474 | 3696 | cat <<_LT_EOF > conftest.$ac_ext |
3697 | /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ | |
3698 | #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) | |
3699 | /* DATA imports from DLLs on WIN32 con't be const, because runtime | |
3700 | relocations are performed -- see ld's documentation on pseudo-relocs. */ | |
3701 | # define LT@&t@_DLSYM_CONST | |
3702 | #elif defined(__osf__) | |
3703 | /* This system does not cope well with relocations in const data. */ | |
3704 | # define LT@&t@_DLSYM_CONST | |
3705 | #else | |
3706 | # define LT@&t@_DLSYM_CONST const | |
3707 | #endif | |
3708 | ||
3475 | 3709 | #ifdef __cplusplus |
3476 | 3710 | extern "C" { |
3477 | 3711 | #endif |
3483 | 3717 | cat <<_LT_EOF >> conftest.$ac_ext |
3484 | 3718 | |
3485 | 3719 | /* The mapping between symbol names and symbols. */ |
3486 | const struct { | |
3720 | LT@&t@_DLSYM_CONST struct { | |
3487 | 3721 | const char *name; |
3488 | 3722 | void *address; |
3489 | 3723 | } |
3509 | 3743 | _LT_EOF |
3510 | 3744 | # Now try linking the two files. |
3511 | 3745 | mv conftest.$ac_objext conftstm.$ac_objext |
3512 | lt_save_LIBS="$LIBS" | |
3513 | lt_save_CFLAGS="$CFLAGS" | |
3746 | lt_globsym_save_LIBS=$LIBS | |
3747 | lt_globsym_save_CFLAGS=$CFLAGS | |
3514 | 3748 | LIBS="conftstm.$ac_objext" |
3515 | 3749 | CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" |
3516 | 3750 | if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then |
3517 | 3751 | pipe_works=yes |
3518 | 3752 | fi |
3519 | LIBS="$lt_save_LIBS" | |
3520 | CFLAGS="$lt_save_CFLAGS" | |
3753 | LIBS=$lt_globsym_save_LIBS | |
3754 | CFLAGS=$lt_globsym_save_CFLAGS | |
3521 | 3755 | else |
3522 | 3756 | echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD |
3523 | 3757 | fi |
3550 | 3784 | AC_MSG_RESULT(ok) |
3551 | 3785 | fi |
3552 | 3786 | |
3787 | # Response file support. | |
3788 | if test "$lt_cv_nm_interface" = "MS dumpbin"; then | |
3789 | nm_file_list_spec='@' | |
3790 | elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then | |
3791 | nm_file_list_spec='@' | |
3792 | fi | |
3793 | ||
3553 | 3794 | _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], |
3554 | 3795 | [Take the output of nm and produce a listing of raw symbols and C names]) |
3555 | 3796 | _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], |
3560 | 3801 | _LT_DECL([global_symbol_to_c_name_address_lib_prefix], |
3561 | 3802 | [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], |
3562 | 3803 | [Transform the output of nm in a C name address pair when lib prefix is needed]) |
3804 | _LT_DECL([], [nm_file_list_spec], [1], | |
3805 | [Specify filename containing input files for $NM]) | |
3563 | 3806 | ]) # _LT_CMD_GLOBAL_SYMBOLS |
3564 | 3807 | |
3565 | 3808 | |
3571 | 3814 | _LT_TAGVAR(lt_prog_compiler_pic, $1)= |
3572 | 3815 | _LT_TAGVAR(lt_prog_compiler_static, $1)= |
3573 | 3816 | |
3574 | AC_MSG_CHECKING([for $compiler option to produce PIC]) | |
3575 | 3817 | m4_if([$1], [CXX], [ |
3576 | 3818 | # C++ specific cases for pic, static, wl, etc. |
3577 | 3819 | if test "$GXX" = yes; then |
3675 | 3917 | # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" |
3676 | 3918 | ;; |
3677 | 3919 | esac |
3920 | ;; | |
3921 | mingw* | cygwin* | os2* | pw32* | cegcc*) | |
3922 | # This hack is so that the source file can tell whether it is being | |
3923 | # built for inclusion in a dll (and should export symbols for example). | |
3924 | m4_if([$1], [GCJ], [], | |
3925 | [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) | |
3678 | 3926 | ;; |
3679 | 3927 | dgux*) |
3680 | 3928 | case $cc_basename in |
4050 | 4298 | _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' |
4051 | 4299 | _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' |
4052 | 4300 | ;; |
4301 | nagfor*) | |
4302 | # NAG Fortran compiler | |
4303 | _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' | |
4304 | _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' | |
4305 | _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' | |
4306 | ;; | |
4053 | 4307 | pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) |
4054 | 4308 | # Portland Group compilers (*not* the Pentium gcc compiler, |
4055 | 4309 | # which looks to be a dead project) |
4169 | 4423 | _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" |
4170 | 4424 | ;; |
4171 | 4425 | esac |
4172 | AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) | |
4173 | _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], | |
4174 | [How to pass a linker flag through the compiler]) | |
4426 | ||
4427 | AC_CACHE_CHECK([for $compiler option to produce PIC], | |
4428 | [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], | |
4429 | [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) | |
4430 | _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) | |
4175 | 4431 | |
4176 | 4432 | # |
4177 | 4433 | # Check to make sure the PIC flag actually works. |
4190 | 4446 | _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], |
4191 | 4447 | [Additional compiler flags for building library objects]) |
4192 | 4448 | |
4449 | _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], | |
4450 | [How to pass a linker flag through the compiler]) | |
4193 | 4451 | # |
4194 | 4452 | # Check to make sure the static flag actually works. |
4195 | 4453 | # |
4210 | 4468 | m4_defun([_LT_LINKER_SHLIBS], |
4211 | 4469 | [AC_REQUIRE([LT_PATH_LD])dnl |
4212 | 4470 | AC_REQUIRE([LT_PATH_NM])dnl |
4471 | m4_require([_LT_PATH_MANIFEST_TOOL])dnl | |
4213 | 4472 | m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
4214 | 4473 | m4_require([_LT_DECL_EGREP])dnl |
4215 | 4474 | m4_require([_LT_DECL_SED])dnl |
4218 | 4477 | AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) |
4219 | 4478 | m4_if([$1], [CXX], [ |
4220 | 4479 | _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' |
4480 | _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] | |
4221 | 4481 | case $host_os in |
4222 | 4482 | aix[[4-9]]*) |
4223 | 4483 | # If we're using GNU nm, then we don't want the "-C" option. |
4232 | 4492 | ;; |
4233 | 4493 | pw32*) |
4234 | 4494 | _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" |
4235 | ;; | |
4495 | ;; | |
4236 | 4496 | cygwin* | mingw* | cegcc*) |
4237 | _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' | |
4238 | ;; | |
4497 | case $cc_basename in | |
4498 | cl*) ;; | |
4499 | *) | |
4500 | _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' | |
4501 | _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] | |
4502 | ;; | |
4503 | esac | |
4504 | ;; | |
4239 | 4505 | *) |
4240 | 4506 | _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' |
4241 | ;; | |
4507 | ;; | |
4242 | 4508 | esac |
4243 | _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] | |
4244 | 4509 | ], [ |
4245 | 4510 | runpath_var= |
4246 | 4511 | _LT_TAGVAR(allow_undefined_flag, $1)= |
4408 | 4673 | _LT_TAGVAR(allow_undefined_flag, $1)=unsupported |
4409 | 4674 | _LT_TAGVAR(always_export_symbols, $1)=no |
4410 | 4675 | _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes |
4411 | _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' | |
4676 | _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' | |
4677 | _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] | |
4412 | 4678 | |
4413 | 4679 | if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then |
4414 | 4680 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' |
4456 | 4722 | if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ |
4457 | 4723 | && test "$tmp_diet" = no |
4458 | 4724 | then |
4459 | tmp_addflag= | |
4725 | tmp_addflag=' $pic_flag' | |
4460 | 4726 | tmp_sharedflag='-shared' |
4461 | 4727 | case $cc_basename,$host_cpu in |
4462 | 4728 | pgcc*) # Portland Group C compiler |
4526 | 4792 | _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' |
4527 | 4793 | wlarc= |
4528 | 4794 | else |
4529 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
4530 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
4795 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
4796 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
4531 | 4797 | fi |
4532 | 4798 | ;; |
4533 | 4799 | |
4545 | 4811 | |
4546 | 4812 | _LT_EOF |
4547 | 4813 | elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then |
4548 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
4549 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
4814 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
4815 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
4550 | 4816 | else |
4551 | 4817 | _LT_TAGVAR(ld_shlibs, $1)=no |
4552 | 4818 | fi |
4592 | 4858 | |
4593 | 4859 | *) |
4594 | 4860 | if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then |
4595 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
4596 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
4861 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
4862 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
4597 | 4863 | else |
4598 | 4864 | _LT_TAGVAR(ld_shlibs, $1)=no |
4599 | 4865 | fi |
4723 | 4989 | _LT_TAGVAR(allow_undefined_flag, $1)='-berok' |
4724 | 4990 | # Determine the default libpath from the value encoded in an |
4725 | 4991 | # empty executable. |
4726 | _LT_SYS_MODULE_PATH_AIX | |
4992 | _LT_SYS_MODULE_PATH_AIX([$1]) | |
4727 | 4993 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" |
4728 | 4994 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" |
4729 | 4995 | else |
4734 | 5000 | else |
4735 | 5001 | # Determine the default libpath from the value encoded in an |
4736 | 5002 | # empty executable. |
4737 | _LT_SYS_MODULE_PATH_AIX | |
5003 | _LT_SYS_MODULE_PATH_AIX([$1]) | |
4738 | 5004 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" |
4739 | 5005 | # Warning - without using the other run time loading flags, |
4740 | 5006 | # -berok will link without error, but may produce a broken library. |
4778 | 5044 | # Microsoft Visual C++. |
4779 | 5045 | # hardcode_libdir_flag_spec is actually meaningless, as there is |
4780 | 5046 | # no search path for DLLs. |
4781 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' | |
4782 | _LT_TAGVAR(allow_undefined_flag, $1)=unsupported | |
4783 | # Tell ltmain to make .lib files, not .a files. | |
4784 | libext=lib | |
4785 | # Tell ltmain to make .dll files, not .so files. | |
4786 | shrext_cmds=".dll" | |
4787 | # FIXME: Setting linknames here is a bad hack. | |
4788 | _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' | |
4789 | # The linker will automatically build a .lib file if we build a DLL. | |
4790 | _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' | |
4791 | # FIXME: Should let the user specify the lib program. | |
4792 | _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' | |
4793 | _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' | |
4794 | _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes | |
5047 | case $cc_basename in | |
5048 | cl*) | |
5049 | # Native MSVC | |
5050 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' | |
5051 | _LT_TAGVAR(allow_undefined_flag, $1)=unsupported | |
5052 | _LT_TAGVAR(always_export_symbols, $1)=yes | |
5053 | _LT_TAGVAR(file_list_spec, $1)='@' | |
5054 | # Tell ltmain to make .lib files, not .a files. | |
5055 | libext=lib | |
5056 | # Tell ltmain to make .dll files, not .so files. | |
5057 | shrext_cmds=".dll" | |
5058 | # FIXME: Setting linknames here is a bad hack. | |
5059 | _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' | |
5060 | _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then | |
5061 | sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; | |
5062 | else | |
5063 | sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; | |
5064 | fi~ | |
5065 | $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ | |
5066 | linknames=' | |
5067 | # The linker will not automatically build a static lib if we build a DLL. | |
5068 | # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' | |
5069 | _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes | |
5070 | _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' | |
5071 | # Don't use ranlib | |
5072 | _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' | |
5073 | _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ | |
5074 | lt_tool_outputfile="@TOOL_OUTPUT@"~ | |
5075 | case $lt_outputfile in | |
5076 | *.exe|*.EXE) ;; | |
5077 | *) | |
5078 | lt_outputfile="$lt_outputfile.exe" | |
5079 | lt_tool_outputfile="$lt_tool_outputfile.exe" | |
5080 | ;; | |
5081 | esac~ | |
5082 | if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then | |
5083 | $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; | |
5084 | $RM "$lt_outputfile.manifest"; | |
5085 | fi' | |
5086 | ;; | |
5087 | *) | |
5088 | # Assume MSVC wrapper | |
5089 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' | |
5090 | _LT_TAGVAR(allow_undefined_flag, $1)=unsupported | |
5091 | # Tell ltmain to make .lib files, not .a files. | |
5092 | libext=lib | |
5093 | # Tell ltmain to make .dll files, not .so files. | |
5094 | shrext_cmds=".dll" | |
5095 | # FIXME: Setting linknames here is a bad hack. | |
5096 | _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' | |
5097 | # The linker will automatically build a .lib file if we build a DLL. | |
5098 | _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' | |
5099 | # FIXME: Should let the user specify the lib program. | |
5100 | _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' | |
5101 | _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes | |
5102 | ;; | |
5103 | esac | |
4795 | 5104 | ;; |
4796 | 5105 | |
4797 | 5106 | darwin* | rhapsody*) |
4829 | 5138 | |
4830 | 5139 | # FreeBSD 3 and greater uses gcc -shared to do shared libraries. |
4831 | 5140 | freebsd* | dragonfly*) |
4832 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' | |
5141 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' | |
4833 | 5142 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' |
4834 | 5143 | _LT_TAGVAR(hardcode_direct, $1)=yes |
4835 | 5144 | _LT_TAGVAR(hardcode_shlibpath_var, $1)=no |
4837 | 5146 | |
4838 | 5147 | hpux9*) |
4839 | 5148 | if test "$GCC" = yes; then |
4840 | _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' | |
5149 | _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' | |
4841 | 5150 | else |
4842 | 5151 | _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' |
4843 | 5152 | fi |
4853 | 5162 | |
4854 | 5163 | hpux10*) |
4855 | 5164 | if test "$GCC" = yes && test "$with_gnu_ld" = no; then |
4856 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' | |
5165 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' | |
4857 | 5166 | else |
4858 | 5167 | _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' |
4859 | 5168 | fi |
4877 | 5186 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' |
4878 | 5187 | ;; |
4879 | 5188 | ia64*) |
4880 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' | |
5189 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' | |
4881 | 5190 | ;; |
4882 | 5191 | *) |
4883 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' | |
5192 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' | |
4884 | 5193 | ;; |
4885 | 5194 | esac |
4886 | 5195 | else |
4927 | 5236 | |
4928 | 5237 | irix5* | irix6* | nonstopux*) |
4929 | 5238 | if test "$GCC" = yes; then |
4930 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
5239 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
4931 | 5240 | # Try to use the -exported_symbol ld option, if it does not |
4932 | 5241 | # work, assume that -exports_file does not work either and |
4933 | 5242 | # implicitly export all symbols. |
4934 | save_LDFLAGS="$LDFLAGS" | |
4935 | LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" | |
4936 | AC_LINK_IFELSE(int foo(void) {}, | |
4937 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' | |
4938 | ) | |
4939 | LDFLAGS="$save_LDFLAGS" | |
5243 | # This should be the same for all languages, so no per-tag cache variable. | |
5244 | AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], | |
5245 | [lt_cv_irix_exported_symbol], | |
5246 | [save_LDFLAGS="$LDFLAGS" | |
5247 | LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" | |
5248 | AC_LINK_IFELSE( | |
5249 | [AC_LANG_SOURCE( | |
5250 | [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], | |
5251 | [C++], [[int foo (void) { return 0; }]], | |
5252 | [Fortran 77], [[ | |
5253 | subroutine foo | |
5254 | end]], | |
5255 | [Fortran], [[ | |
5256 | subroutine foo | |
5257 | end]])])], | |
5258 | [lt_cv_irix_exported_symbol=yes], | |
5259 | [lt_cv_irix_exported_symbol=no]) | |
5260 | LDFLAGS="$save_LDFLAGS"]) | |
5261 | if test "$lt_cv_irix_exported_symbol" = yes; then | |
5262 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' | |
5263 | fi | |
4940 | 5264 | else |
4941 | 5265 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' |
4942 | 5266 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' |
5021 | 5345 | osf4* | osf5*) # as osf3* with the addition of -msym flag |
5022 | 5346 | if test "$GCC" = yes; then |
5023 | 5347 | _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' |
5024 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
5348 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
5025 | 5349 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' |
5026 | 5350 | else |
5027 | 5351 | _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' |
5040 | 5364 | _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' |
5041 | 5365 | if test "$GCC" = yes; then |
5042 | 5366 | wlarc='${wl}' |
5043 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' | |
5367 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' | |
5044 | 5368 | _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ |
5045 | $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' | |
5369 | $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' | |
5046 | 5370 | else |
5047 | 5371 | case `$CC -V 2>&1` in |
5048 | 5372 | *"Compilers 5.0"*) |
5314 | 5638 | to runtime path list]) |
5315 | 5639 | _LT_TAGDECL([], [link_all_deplibs], [0], |
5316 | 5640 | [Whether libtool must link a program against all its dependency libraries]) |
5317 | _LT_TAGDECL([], [fix_srcfile_path], [1], | |
5318 | [Fix the shell variable $srcfile for the compiler]) | |
5319 | 5641 | _LT_TAGDECL([], [always_export_symbols], [0], |
5320 | 5642 | [Set to "yes" if exported symbols are required]) |
5321 | 5643 | _LT_TAGDECL([], [export_symbols_cmds], [2], |
5326 | 5648 | [Symbols that must always be exported]) |
5327 | 5649 | _LT_TAGDECL([], [prelink_cmds], [2], |
5328 | 5650 | [Commands necessary for linking programs (against libraries) with templates]) |
5651 | _LT_TAGDECL([], [postlink_cmds], [2], | |
5652 | [Commands necessary for finishing linking programs]) | |
5329 | 5653 | _LT_TAGDECL([], [file_list_spec], [1], |
5330 | 5654 | [Specify filename containing input files]) |
5331 | 5655 | dnl FIXME: Not yet implemented |
5427 | 5751 | m4_defun([_LT_LANG_CXX_CONFIG], |
5428 | 5752 | [m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
5429 | 5753 | m4_require([_LT_DECL_EGREP])dnl |
5754 | m4_require([_LT_PATH_MANIFEST_TOOL])dnl | |
5430 | 5755 | if test -n "$CXX" && ( test "X$CXX" != "Xno" && |
5431 | 5756 | ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || |
5432 | 5757 | (test "X$CXX" != "Xg++"))) ; then |
5488 | 5813 | |
5489 | 5814 | # Allow CC to be a program name with arguments. |
5490 | 5815 | lt_save_CC=$CC |
5816 | lt_save_CFLAGS=$CFLAGS | |
5491 | 5817 | lt_save_LD=$LD |
5492 | 5818 | lt_save_GCC=$GCC |
5493 | 5819 | GCC=$GXX |
5505 | 5831 | fi |
5506 | 5832 | test -z "${LDCXX+set}" || LD=$LDCXX |
5507 | 5833 | CC=${CXX-"c++"} |
5834 | CFLAGS=$CXXFLAGS | |
5508 | 5835 | compiler=$CC |
5509 | 5836 | _LT_TAGVAR(compiler, $1)=$CC |
5510 | 5837 | _LT_CC_BASENAME([$compiler]) |
5526 | 5853 | # Check if GNU C++ uses GNU ld as the underlying linker, since the |
5527 | 5854 | # archiving commands below assume that GNU ld is being used. |
5528 | 5855 | if test "$with_gnu_ld" = yes; then |
5529 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
5530 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
5856 | _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
5857 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
5531 | 5858 | |
5532 | 5859 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' |
5533 | 5860 | _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' |
5668 | 5995 | _LT_TAGVAR(allow_undefined_flag, $1)='-berok' |
5669 | 5996 | # Determine the default libpath from the value encoded in an empty |
5670 | 5997 | # executable. |
5671 | _LT_SYS_MODULE_PATH_AIX | |
5998 | _LT_SYS_MODULE_PATH_AIX([$1]) | |
5672 | 5999 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" |
5673 | 6000 | |
5674 | 6001 | _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" |
5680 | 6007 | else |
5681 | 6008 | # Determine the default libpath from the value encoded in an |
5682 | 6009 | # empty executable. |
5683 | _LT_SYS_MODULE_PATH_AIX | |
6010 | _LT_SYS_MODULE_PATH_AIX([$1]) | |
5684 | 6011 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" |
5685 | 6012 | # Warning - without using the other run time loading flags, |
5686 | 6013 | # -berok will link without error, but may produce a broken library. |
5722 | 6049 | ;; |
5723 | 6050 | |
5724 | 6051 | cygwin* | mingw* | pw32* | cegcc*) |
5725 | # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, | |
5726 | # as there is no search path for DLLs. | |
5727 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' | |
5728 | _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' | |
5729 | _LT_TAGVAR(allow_undefined_flag, $1)=unsupported | |
5730 | _LT_TAGVAR(always_export_symbols, $1)=no | |
5731 | _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes | |
5732 | ||
5733 | if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then | |
5734 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' | |
5735 | # If the export-symbols file already is a .def file (1st line | |
5736 | # is EXPORTS), use it as is; otherwise, prepend... | |
5737 | _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then | |
5738 | cp $export_symbols $output_objdir/$soname.def; | |
5739 | else | |
5740 | echo EXPORTS > $output_objdir/$soname.def; | |
5741 | cat $export_symbols >> $output_objdir/$soname.def; | |
5742 | fi~ | |
5743 | $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' | |
5744 | else | |
5745 | _LT_TAGVAR(ld_shlibs, $1)=no | |
5746 | fi | |
5747 | ;; | |
6052 | case $GXX,$cc_basename in | |
6053 | ,cl* | no,cl*) | |
6054 | # Native MSVC | |
6055 | # hardcode_libdir_flag_spec is actually meaningless, as there is | |
6056 | # no search path for DLLs. | |
6057 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' | |
6058 | _LT_TAGVAR(allow_undefined_flag, $1)=unsupported | |
6059 | _LT_TAGVAR(always_export_symbols, $1)=yes | |
6060 | _LT_TAGVAR(file_list_spec, $1)='@' | |
6061 | # Tell ltmain to make .lib files, not .a files. | |
6062 | libext=lib | |
6063 | # Tell ltmain to make .dll files, not .so files. | |
6064 | shrext_cmds=".dll" | |
6065 | # FIXME: Setting linknames here is a bad hack. | |
6066 | _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' | |
6067 | _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then | |
6068 | $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; | |
6069 | else | |
6070 | $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; | |
6071 | fi~ | |
6072 | $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ | |
6073 | linknames=' | |
6074 | # The linker will not automatically build a static lib if we build a DLL. | |
6075 | # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' | |
6076 | _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes | |
6077 | # Don't use ranlib | |
6078 | _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' | |
6079 | _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ | |
6080 | lt_tool_outputfile="@TOOL_OUTPUT@"~ | |
6081 | case $lt_outputfile in | |
6082 | *.exe|*.EXE) ;; | |
6083 | *) | |
6084 | lt_outputfile="$lt_outputfile.exe" | |
6085 | lt_tool_outputfile="$lt_tool_outputfile.exe" | |
6086 | ;; | |
6087 | esac~ | |
6088 | func_to_tool_file "$lt_outputfile"~ | |
6089 | if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then | |
6090 | $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; | |
6091 | $RM "$lt_outputfile.manifest"; | |
6092 | fi' | |
6093 | ;; | |
6094 | *) | |
6095 | # g++ | |
6096 | # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, | |
6097 | # as there is no search path for DLLs. | |
6098 | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' | |
6099 | _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' | |
6100 | _LT_TAGVAR(allow_undefined_flag, $1)=unsupported | |
6101 | _LT_TAGVAR(always_export_symbols, $1)=no | |
6102 | _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes | |
6103 | ||
6104 | if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then | |
6105 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' | |
6106 | # If the export-symbols file already is a .def file (1st line | |
6107 | # is EXPORTS), use it as is; otherwise, prepend... | |
6108 | _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then | |
6109 | cp $export_symbols $output_objdir/$soname.def; | |
6110 | else | |
6111 | echo EXPORTS > $output_objdir/$soname.def; | |
6112 | cat $export_symbols >> $output_objdir/$soname.def; | |
6113 | fi~ | |
6114 | $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' | |
6115 | else | |
6116 | _LT_TAGVAR(ld_shlibs, $1)=no | |
6117 | fi | |
6118 | ;; | |
6119 | esac | |
6120 | ;; | |
5748 | 6121 | darwin* | rhapsody*) |
5749 | 6122 | _LT_DARWIN_LINKER_FEATURES($1) |
5750 | 6123 | ;; |
5819 | 6192 | ;; |
5820 | 6193 | *) |
5821 | 6194 | if test "$GXX" = yes; then |
5822 | _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' | |
6195 | _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' | |
5823 | 6196 | else |
5824 | 6197 | # FIXME: insert proper C++ library support |
5825 | 6198 | _LT_TAGVAR(ld_shlibs, $1)=no |
5890 | 6263 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' |
5891 | 6264 | ;; |
5892 | 6265 | ia64*) |
5893 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
6266 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
5894 | 6267 | ;; |
5895 | 6268 | *) |
5896 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
6269 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
5897 | 6270 | ;; |
5898 | 6271 | esac |
5899 | 6272 | fi |
5934 | 6307 | *) |
5935 | 6308 | if test "$GXX" = yes; then |
5936 | 6309 | if test "$with_gnu_ld" = no; then |
5937 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
6310 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
5938 | 6311 | else |
5939 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' | |
6312 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' | |
5940 | 6313 | fi |
5941 | 6314 | fi |
5942 | 6315 | _LT_TAGVAR(link_all_deplibs, $1)=yes |
6214 | 6587 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' |
6215 | 6588 | ;; |
6216 | 6589 | *) |
6217 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
6590 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' | |
6218 | 6591 | ;; |
6219 | 6592 | esac |
6220 | 6593 | |
6301 | 6674 | if test "$GXX" = yes && test "$with_gnu_ld" = no; then |
6302 | 6675 | _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' |
6303 | 6676 | if $CC --version | $GREP -v '^2\.7' > /dev/null; then |
6304 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' | |
6677 | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' | |
6305 | 6678 | _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ |
6306 | $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' | |
6679 | $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' | |
6307 | 6680 | |
6308 | 6681 | # Commands to make compiler produce verbose output that lists |
6309 | 6682 | # what "hidden" libraries, object files and flags are used when |
6432 | 6805 | fi # test -n "$compiler" |
6433 | 6806 | |
6434 | 6807 | CC=$lt_save_CC |
6808 | CFLAGS=$lt_save_CFLAGS | |
6435 | 6809 | LDCXX=$LD |
6436 | 6810 | LD=$lt_save_LD |
6437 | 6811 | GCC=$lt_save_GCC |
6446 | 6820 | ])# _LT_LANG_CXX_CONFIG |
6447 | 6821 | |
6448 | 6822 | |
6823 | # _LT_FUNC_STRIPNAME_CNF | |
6824 | # ---------------------- | |
6825 | # func_stripname_cnf prefix suffix name | |
6826 | # strip PREFIX and SUFFIX off of NAME. | |
6827 | # PREFIX and SUFFIX must not contain globbing or regex special | |
6828 | # characters, hashes, percent signs, but SUFFIX may contain a leading | |
6829 | # dot (in which case that matches only a dot). | |
6830 | # | |
6831 | # This function is identical to the (non-XSI) version of func_stripname, | |
6832 | # except this one can be used by m4 code that may be executed by configure, | |
6833 | # rather than the libtool script. | |
6834 | m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl | |
6835 | AC_REQUIRE([_LT_DECL_SED]) | |
6836 | AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) | |
6837 | func_stripname_cnf () | |
6838 | { | |
6839 | case ${2} in | |
6840 | .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; | |
6841 | *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; | |
6842 | esac | |
6843 | } # func_stripname_cnf | |
6844 | ])# _LT_FUNC_STRIPNAME_CNF | |
6845 | ||
6449 | 6846 | # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) |
6450 | 6847 | # --------------------------------- |
6451 | 6848 | # Figure out "hidden" library dependencies from verbose |
6454 | 6851 | # objects, libraries and library flags. |
6455 | 6852 | m4_defun([_LT_SYS_HIDDEN_LIBDEPS], |
6456 | 6853 | [m4_require([_LT_FILEUTILS_DEFAULTS])dnl |
6854 | AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl | |
6457 | 6855 | # Dependencies to place before and after the object being linked: |
6458 | 6856 | _LT_TAGVAR(predep_objects, $1)= |
6459 | 6857 | _LT_TAGVAR(postdep_objects, $1)= |
6504 | 6902 | }; |
6505 | 6903 | _LT_EOF |
6506 | 6904 | ]) |
6905 | ||
6906 | _lt_libdeps_save_CFLAGS=$CFLAGS | |
6907 | case "$CC $CFLAGS " in #( | |
6908 | *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; | |
6909 | *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; | |
6910 | esac | |
6911 | ||
6507 | 6912 | dnl Parse the compiler output and extract the necessary |
6508 | 6913 | dnl objects, libraries and library flags. |
6509 | 6914 | if AC_TRY_EVAL(ac_compile); then |
6515 | 6920 | pre_test_object_deps_done=no |
6516 | 6921 | |
6517 | 6922 | for p in `eval "$output_verbose_link_cmd"`; do |
6518 | case $p in | |
6923 | case ${prev}${p} in | |
6519 | 6924 | |
6520 | 6925 | -L* | -R* | -l*) |
6521 | 6926 | # Some compilers place space between "-{L,R}" and the path. |
6524 | 6929 | test $p = "-R"; then |
6525 | 6930 | prev=$p |
6526 | 6931 | continue |
6527 | else | |
6528 | prev= | |
6529 | 6932 | fi |
6530 | 6933 | |
6934 | # Expand the sysroot to ease extracting the directories later. | |
6935 | if test -z "$prev"; then | |
6936 | case $p in | |
6937 | -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; | |
6938 | -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; | |
6939 | -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; | |
6940 | esac | |
6941 | fi | |
6942 | case $p in | |
6943 | =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; | |
6944 | esac | |
6531 | 6945 | if test "$pre_test_object_deps_done" = no; then |
6532 | case $p in | |
6533 | -L* | -R*) | |
6946 | case ${prev} in | |
6947 | -L | -R) | |
6534 | 6948 | # Internal compiler library paths should come after those |
6535 | 6949 | # provided the user. The postdeps already come after the |
6536 | 6950 | # user supplied libs so there is no need to process them. |
6550 | 6964 | _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" |
6551 | 6965 | fi |
6552 | 6966 | fi |
6967 | prev= | |
6553 | 6968 | ;; |
6554 | 6969 | |
6970 | *.lto.$objext) ;; # Ignore GCC LTO objects | |
6555 | 6971 | *.$objext) |
6556 | 6972 | # This assumes that the test object file only shows up |
6557 | 6973 | # once in the compiler output. |
6587 | 7003 | fi |
6588 | 7004 | |
6589 | 7005 | $RM -f confest.$objext |
7006 | CFLAGS=$_lt_libdeps_save_CFLAGS | |
6590 | 7007 | |
6591 | 7008 | # PORTME: override above test on systems where it is broken |
6592 | 7009 | m4_if([$1], [CXX], |
6736 | 7153 | # Allow CC to be a program name with arguments. |
6737 | 7154 | lt_save_CC="$CC" |
6738 | 7155 | lt_save_GCC=$GCC |
7156 | lt_save_CFLAGS=$CFLAGS | |
6739 | 7157 | CC=${F77-"f77"} |
7158 | CFLAGS=$FFLAGS | |
6740 | 7159 | compiler=$CC |
6741 | 7160 | _LT_TAGVAR(compiler, $1)=$CC |
6742 | 7161 | _LT_CC_BASENAME([$compiler]) |
6790 | 7209 | |
6791 | 7210 | GCC=$lt_save_GCC |
6792 | 7211 | CC="$lt_save_CC" |
7212 | CFLAGS="$lt_save_CFLAGS" | |
6793 | 7213 | fi # test "$_lt_disable_F77" != yes |
6794 | 7214 | |
6795 | 7215 | AC_LANG_POP |
6866 | 7286 | # Allow CC to be a program name with arguments. |
6867 | 7287 | lt_save_CC="$CC" |
6868 | 7288 | lt_save_GCC=$GCC |
7289 | lt_save_CFLAGS=$CFLAGS | |
6869 | 7290 | CC=${FC-"f95"} |
7291 | CFLAGS=$FCFLAGS | |
6870 | 7292 | compiler=$CC |
6871 | 7293 | GCC=$ac_cv_fc_compiler_gnu |
6872 | 7294 | |
6922 | 7344 | fi # test -n "$compiler" |
6923 | 7345 | |
6924 | 7346 | GCC=$lt_save_GCC |
6925 | CC="$lt_save_CC" | |
7347 | CC=$lt_save_CC | |
7348 | CFLAGS=$lt_save_CFLAGS | |
6926 | 7349 | fi # test "$_lt_disable_FC" != yes |
6927 | 7350 | |
6928 | 7351 | AC_LANG_POP |
6959 | 7382 | _LT_LINKER_BOILERPLATE |
6960 | 7383 | |
6961 | 7384 | # Allow CC to be a program name with arguments. |
6962 | lt_save_CC="$CC" | |
7385 | lt_save_CC=$CC | |
7386 | lt_save_CFLAGS=$CFLAGS | |
6963 | 7387 | lt_save_GCC=$GCC |
6964 | 7388 | GCC=yes |
6965 | 7389 | CC=${GCJ-"gcj"} |
7390 | CFLAGS=$GCJFLAGS | |
6966 | 7391 | compiler=$CC |
6967 | 7392 | _LT_TAGVAR(compiler, $1)=$CC |
6968 | 7393 | _LT_TAGVAR(LD, $1)="$LD" |
6993 | 7418 | AC_LANG_RESTORE |
6994 | 7419 | |
6995 | 7420 | GCC=$lt_save_GCC |
6996 | CC="$lt_save_CC" | |
7421 | CC=$lt_save_CC | |
7422 | CFLAGS=$lt_save_CFLAGS | |
6997 | 7423 | ])# _LT_LANG_GCJ_CONFIG |
6998 | 7424 | |
6999 | 7425 | |
7028 | 7454 | |
7029 | 7455 | # Allow CC to be a program name with arguments. |
7030 | 7456 | lt_save_CC="$CC" |
7457 | lt_save_CFLAGS=$CFLAGS | |
7031 | 7458 | lt_save_GCC=$GCC |
7032 | 7459 | GCC= |
7033 | 7460 | CC=${RC-"windres"} |
7461 | CFLAGS= | |
7034 | 7462 | compiler=$CC |
7035 | 7463 | _LT_TAGVAR(compiler, $1)=$CC |
7036 | 7464 | _LT_CC_BASENAME([$compiler]) |
7043 | 7471 | |
7044 | 7472 | GCC=$lt_save_GCC |
7045 | 7473 | AC_LANG_RESTORE |
7046 | CC="$lt_save_CC" | |
7474 | CC=$lt_save_CC | |
7475 | CFLAGS=$lt_save_CFLAGS | |
7047 | 7476 | ])# _LT_LANG_RC_CONFIG |
7048 | 7477 | |
7049 | 7478 | |
7102 | 7531 | AC_SUBST([OBJDUMP]) |
7103 | 7532 | ]) |
7104 | 7533 | |
7534 | # _LT_DECL_DLLTOOL | |
7535 | # ---------------- | |
7536 | # Ensure DLLTOOL variable is set. | |
7537 | m4_defun([_LT_DECL_DLLTOOL], | |
7538 | [AC_CHECK_TOOL(DLLTOOL, dlltool, false) | |
7539 | test -z "$DLLTOOL" && DLLTOOL=dlltool | |
7540 | _LT_DECL([], [DLLTOOL], [1], [DLL creation program]) | |
7541 | AC_SUBST([DLLTOOL]) | |
7542 | ]) | |
7105 | 7543 | |
7106 | 7544 | # _LT_DECL_SED |
7107 | 7545 | # ------------ |
7195 | 7633 | # Try some XSI features |
7196 | 7634 | xsi_shell=no |
7197 | 7635 | ( _lt_dummy="a/b/c" |
7198 | test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \ | |
7199 | = c,a/b,, \ | |
7636 | test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ | |
7637 | = c,a/b,b/c, \ | |
7200 | 7638 | && eval 'test $(( 1 + 1 )) -eq 2 \ |
7201 | 7639 | && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ |
7202 | 7640 | && xsi_shell=yes |
7235 | 7673 | ])# _LT_CHECK_SHELL_FEATURES |
7236 | 7674 | |
7237 | 7675 | |
7238 | # _LT_PROG_XSI_SHELLFNS | |
7239 | # --------------------- | |
7240 | # Bourne and XSI compatible variants of some useful shell functions. | |
7241 | m4_defun([_LT_PROG_XSI_SHELLFNS], | |
7242 | [case $xsi_shell in | |
7243 | yes) | |
7244 | cat << \_LT_EOF >> "$cfgfile" | |
7245 | ||
7246 | # func_dirname file append nondir_replacement | |
7247 | # Compute the dirname of FILE. If nonempty, add APPEND to the result, | |
7248 | # otherwise set result to NONDIR_REPLACEMENT. | |
7249 | func_dirname () | |
7250 | { | |
7251 | case ${1} in | |
7252 | */*) func_dirname_result="${1%/*}${2}" ;; | |
7253 | * ) func_dirname_result="${3}" ;; | |
7254 | esac | |
7255 | } | |
7256 | ||
7257 | # func_basename file | |
7258 | func_basename () | |
7259 | { | |
7260 | func_basename_result="${1##*/}" | |
7261 | } | |
7262 | ||
7263 | # func_dirname_and_basename file append nondir_replacement | |
7264 | # perform func_basename and func_dirname in a single function | |
7265 | # call: | |
7266 | # dirname: Compute the dirname of FILE. If nonempty, | |
7267 | # add APPEND to the result, otherwise set result | |
7268 | # to NONDIR_REPLACEMENT. | |
7269 | # value returned in "$func_dirname_result" | |
7270 | # basename: Compute filename of FILE. | |
7271 | # value retuned in "$func_basename_result" | |
7272 | # Implementation must be kept synchronized with func_dirname | |
7273 | # and func_basename. For efficiency, we do not delegate to | |
7274 | # those functions but instead duplicate the functionality here. | |
7275 | func_dirname_and_basename () | |
7276 | { | |
7277 | case ${1} in | |
7278 | */*) func_dirname_result="${1%/*}${2}" ;; | |
7279 | * ) func_dirname_result="${3}" ;; | |
7280 | esac | |
7281 | func_basename_result="${1##*/}" | |
7282 | } | |
7283 | ||
7284 | # func_stripname prefix suffix name | |
7285 | # strip PREFIX and SUFFIX off of NAME. | |
7286 | # PREFIX and SUFFIX must not contain globbing or regex special | |
7287 | # characters, hashes, percent signs, but SUFFIX may contain a leading | |
7288 | # dot (in which case that matches only a dot). | |
7289 | func_stripname () | |
7290 | { | |
7291 | # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are | |
7292 | # positional parameters, so assign one to ordinary parameter first. | |
7293 | func_stripname_result=${3} | |
7294 | func_stripname_result=${func_stripname_result#"${1}"} | |
7295 | func_stripname_result=${func_stripname_result%"${2}"} | |
7296 | } | |
7297 | ||
7298 | # func_opt_split | |
7299 | func_opt_split () | |
7300 | { | |
7301 | func_opt_split_opt=${1%%=*} | |
7302 | func_opt_split_arg=${1#*=} | |
7303 | } | |
7304 | ||
7305 | # func_lo2o object | |
7306 | func_lo2o () | |
7307 | { | |
7308 | case ${1} in | |
7309 | *.lo) func_lo2o_result=${1%.lo}.${objext} ;; | |
7310 | *) func_lo2o_result=${1} ;; | |
7311 | esac | |
7312 | } | |
7313 | ||
7314 | # func_xform libobj-or-source | |
7315 | func_xform () | |
7316 | { | |
7317 | func_xform_result=${1%.*}.lo | |
7318 | } | |
7319 | ||
7320 | # func_arith arithmetic-term... | |
7321 | func_arith () | |
7322 | { | |
7323 | func_arith_result=$(( $[*] )) | |
7324 | } | |
7325 | ||
7326 | # func_len string | |
7327 | # STRING may not start with a hyphen. | |
7328 | func_len () | |
7329 | { | |
7330 | func_len_result=${#1} | |
7331 | } | |
7332 | ||
7333 | _LT_EOF | |
7676 | # _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY) | |
7677 | # ------------------------------------------------------ | |
7678 | # In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and | |
7679 | # '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY. | |
7680 | m4_defun([_LT_PROG_FUNCTION_REPLACE], | |
7681 | [dnl { | |
7682 | sed -e '/^$1 ()$/,/^} # $1 /c\ | |
7683 | $1 ()\ | |
7684 | {\ | |
7685 | m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1]) | |
7686 | } # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \ | |
7687 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
7688 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
7689 | test 0 -eq $? || _lt_function_replace_fail=: | |
7690 | ]) | |
7691 | ||
7692 | ||
7693 | # _LT_PROG_REPLACE_SHELLFNS | |
7694 | # ------------------------- | |
7695 | # Replace existing portable implementations of several shell functions with | |
7696 | # equivalent extended shell implementations where those features are available.. | |
7697 | m4_defun([_LT_PROG_REPLACE_SHELLFNS], | |
7698 | [if test x"$xsi_shell" = xyes; then | |
7699 | _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl | |
7700 | case ${1} in | |
7701 | */*) func_dirname_result="${1%/*}${2}" ;; | |
7702 | * ) func_dirname_result="${3}" ;; | |
7703 | esac]) | |
7704 | ||
7705 | _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl | |
7706 | func_basename_result="${1##*/}"]) | |
7707 | ||
7708 | _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl | |
7709 | case ${1} in | |
7710 | */*) func_dirname_result="${1%/*}${2}" ;; | |
7711 | * ) func_dirname_result="${3}" ;; | |
7712 | esac | |
7713 | func_basename_result="${1##*/}"]) | |
7714 | ||
7715 | _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl | |
7716 | # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are | |
7717 | # positional parameters, so assign one to ordinary parameter first. | |
7718 | func_stripname_result=${3} | |
7719 | func_stripname_result=${func_stripname_result#"${1}"} | |
7720 | func_stripname_result=${func_stripname_result%"${2}"}]) | |
7721 | ||
7722 | _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl | |
7723 | func_split_long_opt_name=${1%%=*} | |
7724 | func_split_long_opt_arg=${1#*=}]) | |
7725 | ||
7726 | _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl | |
7727 | func_split_short_opt_arg=${1#??} | |
7728 | func_split_short_opt_name=${1%"$func_split_short_opt_arg"}]) | |
7729 | ||
7730 | _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl | |
7731 | case ${1} in | |
7732 | *.lo) func_lo2o_result=${1%.lo}.${objext} ;; | |
7733 | *) func_lo2o_result=${1} ;; | |
7734 | esac]) | |
7735 | ||
7736 | _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo]) | |
7737 | ||
7738 | _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))]) | |
7739 | ||
7740 | _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}]) | |
7741 | fi | |
7742 | ||
7743 | if test x"$lt_shell_append" = xyes; then | |
7744 | _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"]) | |
7745 | ||
7746 | _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl | |
7747 | func_quote_for_eval "${2}" | |
7748 | dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \ | |
7749 | eval "${1}+=\\\\ \\$func_quote_for_eval_result"]) | |
7750 | ||
7751 | # Save a `func_append' function call where possible by direct use of '+=' | |
7752 | sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ | |
7753 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
7754 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
7755 | test 0 -eq $? || _lt_function_replace_fail=: | |
7756 | else | |
7757 | # Save a `func_append' function call even when '+=' is not available | |
7758 | sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ | |
7759 | && mv -f "$cfgfile.tmp" "$cfgfile" \ | |
7760 | || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") | |
7761 | test 0 -eq $? || _lt_function_replace_fail=: | |
7762 | fi | |
7763 | ||
7764 | if test x"$_lt_function_replace_fail" = x":"; then | |
7765 | AC_MSG_WARN([Unable to substitute extended shell functions in $ofile]) | |
7766 | fi | |
7767 | ]) | |
7768 | ||
7769 | # _LT_PATH_CONVERSION_FUNCTIONS | |
7770 | # ----------------------------- | |
7771 | # Determine which file name conversion functions should be used by | |
7772 | # func_to_host_file (and, implicitly, by func_to_host_path). These are needed | |
7773 | # for certain cross-compile configurations and native mingw. | |
7774 | m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], | |
7775 | [AC_REQUIRE([AC_CANONICAL_HOST])dnl | |
7776 | AC_REQUIRE([AC_CANONICAL_BUILD])dnl | |
7777 | AC_MSG_CHECKING([how to convert $build file names to $host format]) | |
7778 | AC_CACHE_VAL(lt_cv_to_host_file_cmd, | |
7779 | [case $host in | |
7780 | *-*-mingw* ) | |
7781 | case $build in | |
7782 | *-*-mingw* ) # actually msys | |
7783 | lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 | |
7784 | ;; | |
7785 | *-*-cygwin* ) | |
7786 | lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 | |
7787 | ;; | |
7788 | * ) # otherwise, assume *nix | |
7789 | lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 | |
7790 | ;; | |
7791 | esac | |
7334 | 7792 | ;; |
7335 | *) # Bourne compatible functions. | |
7336 | cat << \_LT_EOF >> "$cfgfile" | |
7337 | ||
7338 | # func_dirname file append nondir_replacement | |
7339 | # Compute the dirname of FILE. If nonempty, add APPEND to the result, | |
7340 | # otherwise set result to NONDIR_REPLACEMENT. | |
7341 | func_dirname () | |
7342 | { | |
7343 | # Extract subdirectory from the argument. | |
7344 | func_dirname_result=`$ECHO "${1}" | $SED "$dirname"` | |
7345 | if test "X$func_dirname_result" = "X${1}"; then | |
7346 | func_dirname_result="${3}" | |
7347 | else | |
7348 | func_dirname_result="$func_dirname_result${2}" | |
7349 | fi | |
7350 | } | |
7351 | ||
7352 | # func_basename file | |
7353 | func_basename () | |
7354 | { | |
7355 | func_basename_result=`$ECHO "${1}" | $SED "$basename"` | |
7356 | } | |
7357 | ||
7358 | dnl func_dirname_and_basename | |
7359 | dnl A portable version of this function is already defined in general.m4sh | |
7360 | dnl so there is no need for it here. | |
7361 | ||
7362 | # func_stripname prefix suffix name | |
7363 | # strip PREFIX and SUFFIX off of NAME. | |
7364 | # PREFIX and SUFFIX must not contain globbing or regex special | |
7365 | # characters, hashes, percent signs, but SUFFIX may contain a leading | |
7366 | # dot (in which case that matches only a dot). | |
7367 | # func_strip_suffix prefix name | |
7368 | func_stripname () | |
7369 | { | |
7370 | case ${2} in | |
7371 | .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; | |
7372 | *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; | |
7373 | esac | |
7374 | } | |
7375 | ||
7376 | # sed scripts: | |
7377 | my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q' | |
7378 | my_sed_long_arg='1s/^-[[^=]]*=//' | |
7379 | ||
7380 | # func_opt_split | |
7381 | func_opt_split () | |
7382 | { | |
7383 | func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"` | |
7384 | func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"` | |
7385 | } | |
7386 | ||
7387 | # func_lo2o object | |
7388 | func_lo2o () | |
7389 | { | |
7390 | func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` | |
7391 | } | |
7392 | ||
7393 | # func_xform libobj-or-source | |
7394 | func_xform () | |
7395 | { | |
7396 | func_xform_result=`$ECHO "${1}" | $SED 's/\.[[^.]]*$/.lo/'` | |
7397 | } | |
7398 | ||
7399 | # func_arith arithmetic-term... | |
7400 | func_arith () | |
7401 | { | |
7402 | func_arith_result=`expr "$[@]"` | |
7403 | } | |
7404 | ||
7405 | # func_len string | |
7406 | # STRING may not start with a hyphen. | |
7407 | func_len () | |
7408 | { | |
7409 | func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len` | |
7410 | } | |
7411 | ||
7412 | _LT_EOF | |
7793 | *-*-cygwin* ) | |
7794 | case $build in | |
7795 | *-*-mingw* ) # actually msys | |
7796 | lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin | |
7797 | ;; | |
7798 | *-*-cygwin* ) | |
7799 | lt_cv_to_host_file_cmd=func_convert_file_noop | |
7800 | ;; | |
7801 | * ) # otherwise, assume *nix | |
7802 | lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin | |
7803 | ;; | |
7804 | esac | |
7805 | ;; | |
7806 | * ) # unhandled hosts (and "normal" native builds) | |
7807 | lt_cv_to_host_file_cmd=func_convert_file_noop | |
7808 | ;; | |
7413 | 7809 | esac |
7414 | ||
7415 | case $lt_shell_append in | |
7416 | yes) | |
7417 | cat << \_LT_EOF >> "$cfgfile" | |
7418 | ||
7419 | # func_append var value | |
7420 | # Append VALUE to the end of shell variable VAR. | |
7421 | func_append () | |
7422 | { | |
7423 | eval "$[1]+=\$[2]" | |
7424 | } | |
7425 | _LT_EOF | |
7810 | ]) | |
7811 | to_host_file_cmd=$lt_cv_to_host_file_cmd | |
7812 | AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) | |
7813 | _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], | |
7814 | [0], [convert $build file names to $host format])dnl | |
7815 | ||
7816 | AC_MSG_CHECKING([how to convert $build file names to toolchain format]) | |
7817 | AC_CACHE_VAL(lt_cv_to_tool_file_cmd, | |
7818 | [#assume ordinary cross tools, or native build. | |
7819 | lt_cv_to_tool_file_cmd=func_convert_file_noop | |
7820 | case $host in | |
7821 | *-*-mingw* ) | |
7822 | case $build in | |
7823 | *-*-mingw* ) # actually msys | |
7824 | lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 | |
7825 | ;; | |
7826 | esac | |
7426 | 7827 | ;; |
7427 | *) | |
7428 | cat << \_LT_EOF >> "$cfgfile" | |
7429 | ||
7430 | # func_append var value | |
7431 | # Append VALUE to the end of shell variable VAR. | |
7432 | func_append () | |
7433 | { | |
7434 | eval "$[1]=\$$[1]\$[2]" | |
7435 | } | |
7436 | ||
7437 | _LT_EOF | |
7438 | ;; | |
7439 | esac | |
7828 | esac | |
7440 | 7829 | ]) |
7830 | to_tool_file_cmd=$lt_cv_to_tool_file_cmd | |
7831 | AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) | |
7832 | _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], | |
7833 | [0], [convert $build files to toolchain format])dnl | |
7834 | ])# _LT_PATH_CONVERSION_FUNCTIONS |
6 | 6 | # unlimited permission to copy and/or distribute it, with or without |
7 | 7 | # modifications, as long as this notice is preserved. |
8 | 8 | |
9 | # Generated from ltversion.in. | |
9 | # @configure_input@ | |
10 | 10 | |
11 | # serial 3175 ltversion.m4 | |
11 | # serial 3293 ltversion.m4 | |
12 | 12 | # This file is part of GNU Libtool |
13 | 13 | |
14 | m4_define([LT_PACKAGE_VERSION], [2.2.10]) | |
15 | m4_define([LT_PACKAGE_REVISION], [1.3175]) | |
14 | m4_define([LT_PACKAGE_VERSION], [2.4]) | |
15 | m4_define([LT_PACKAGE_REVISION], [1.3293]) | |
16 | 16 | |
17 | 17 | AC_DEFUN([LTVERSION_VERSION], |
18 | [macro_version='2.2.10' | |
19 | macro_revision='1.3175' | |
18 | [macro_version='2.4' | |
19 | macro_revision='1.3293' | |
20 | 20 | _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) |
21 | 21 | _LT_DECL(, macro_revision, 0) |
22 | 22 | ]) |
0 | /* $Id: BurgerSpaceClient.cpp,v 1.3 2010/09/16 03:22:22 sarrazip Exp $ | |
0 | /* $Id: BurgerSpaceClient.cpp,v 1.5 2013/02/25 05:04:43 sarrazip Exp $ | |
1 | 1 | BurgerSpaceClient.cpp - Game client |
2 | 2 | |
3 | 3 | burgerspace - A hamburger-smashing video game. |
4 | Copyright (C) 2001-2010 Pierre Sarrazin <http://sarrazip.com/> | |
4 | Copyright (C) 2001-2013 Pierre Sarrazin <http://sarrazip.com/> | |
5 | 5 | |
6 | 6 | This program is free software; you can redistribute it and/or |
7 | 7 | modify it under the terms of the GNU General Public License |
88 | 88 | levelNoAreaSize(), |
89 | 89 | currentPauseMessage(), |
90 | 90 | gameMode(IN_GAME), |
91 | slotDirCursorPos(1), | |
91 | 92 | theSoundMixer(NULL), |
92 | 93 | useSound(_useSound), |
93 | 94 | ingredientBouncesChunk(), |
676 | 677 | */ |
677 | 678 | { |
678 | 679 | if (lastKeyPressed >= SDLK_1 && lastKeyPressed <= SDLK_9) |
679 | { | |
680 | int slotNum = int(lastKeyPressed - SDLK_1) + 1; | |
681 | lastKeyPressed = SDLK_UNKNOWN; | |
682 | return slotNum; | |
683 | } | |
680 | return int(lastKeyPressed - SDLK_1) + 1; | |
684 | 681 | |
685 | 682 | if (lastKeyPressed == SDLK_ESCAPE) |
686 | { | |
687 | lastKeyPressed = SDLK_UNKNOWN; | |
688 | 683 | return -2; |
689 | } | |
684 | ||
685 | // Manage cursor: up and down arrows, and Enter. | |
686 | // | |
687 | if (lastKeyPressed == SDLK_UP) | |
688 | { | |
689 | slotDirCursorPos = (slotDirCursorPos + 7) % 9 + 1; | |
690 | return -1; | |
691 | } | |
692 | if (lastKeyPressed == SDLK_DOWN) | |
693 | { | |
694 | slotDirCursorPos = slotDirCursorPos % 9 + 1; | |
695 | return -1; | |
696 | } | |
697 | if (lastKeyPressed == SDLK_RETURN) | |
698 | return slotDirCursorPos; | |
690 | 699 | |
691 | 700 | return -1; |
692 | 701 | } |
763 | 772 | #ifndef _MSC_VER |
764 | 773 | int fontHeight = getFontDimensions().y; |
765 | 774 | int y = 11 * fontHeight; |
766 | writeStringXCentered(" ", y += fontHeight); | |
767 | writeStringXCentered(" No Save Time ", y += fontHeight); | |
768 | writeStringXCentered(" -- ------------------- ", y += fontHeight); | |
775 | writeStringXCentered(" ", y += fontHeight); | |
776 | writeStringXCentered(" No Save Time ", y += fontHeight); | |
777 | writeStringXCentered(" -- ------------------- ", y += fontHeight); | |
769 | 778 | |
770 | 779 | string dirname = getSavedGamesDir(); |
771 | 780 | |
788 | 797 | strftime(fileTime, sizeof(fileTime), "%Y-%m-%d %H:%M:%S", &t); |
789 | 798 | } |
790 | 799 | } |
791 | snprintf(slotDesc, sizeof(slotDesc), " %u %-19s ", slotNum, fileTime); | |
800 | const char *leftCursor = (slotNum == slotDirCursorPos ? "->" : " "); | |
801 | const char *rightCursor = (slotNum == slotDirCursorPos ? "<-" : " "); | |
802 | snprintf(slotDesc, sizeof(slotDesc), " %s %u %-19s %s ", | |
803 | leftCursor, slotNum, fileTime, rightCursor); | |
792 | 804 | writeStringXCentered(string(slotDesc), y += fontHeight); |
793 | 805 | } |
794 | 806 | |
848 | 860 | void |
849 | 861 | BurgerSpaceClient::drawLoadDialog() |
850 | 862 | { |
851 | showDialogBox(" LOAD GAME: which slot? (1-9, Escape=cancel) "); | |
863 | showDialogBox(" LOAD GAME: which slot? (1-9, up/down/Enter, Escape=cancel) "); | |
852 | 864 | showSlotDirectory(); |
853 | 865 | } |
854 | 866 | |
882 | 894 | { |
883 | 895 | int errorCode = serverInterface->loadGame(in); |
884 | 896 | if (errorCode != 0) |
885 | msg << "Failed to load from slot" << slotNum; | |
897 | msg << "Failed to load from slot " << slotNum << ": error code #" << errorCode; | |
886 | 898 | else |
887 | 899 | { |
888 | 900 | // Show the new game situation: |
0 | /* $Id: BurgerSpaceClient.h,v 1.2 2010/05/26 03:13:01 sarrazip Exp $ | |
0 | /* $Id: BurgerSpaceClient.h,v 1.4 2013/02/25 05:04:43 sarrazip Exp $ | |
1 | 1 | BurgerSpaceClient.h - Game client |
2 | 2 | |
3 | 3 | burgerspace - A hamburger-smashing video game. |
4 | Copyright (C) 2008-2010 Pierre Sarrazin <http://sarrazip.com/> | |
4 | Copyright (C) 2001-2013 Pierre Sarrazin <http://sarrazip.com/> | |
5 | 5 | |
6 | 6 | This program is free software; you can redistribute it and/or |
7 | 7 | modify it under the terms of the GNU General Public License |
153 | 153 | |
154 | 154 | GameMode gameMode; |
155 | 155 | |
156 | size_t slotDirCursorPos; // 1..9; used by getSlotNumber() | |
157 | ||
156 | 158 | /* SOUND EFFECTS: |
157 | 159 | */ |
158 | 160 | flatzebra::SoundMixer *theSoundMixer; // see method playSoundEffect() |
0 | /* $Id: BurgerSpaceServer.cpp,v 1.7 2010/12/31 04:58:16 sarrazip Exp $ | |
0 | /* $Id: BurgerSpaceServer.cpp,v 1.9 2013/02/25 05:04:43 sarrazip Exp $ | |
1 | 1 | BurgerSpaceServer.cpp - Main engine |
2 | 2 | |
3 | 3 | burgerspace - A hamburger-smashing video game. |
4 | Copyright (C) 2001-2008 Pierre Sarrazin <http://sarrazip.com/> | |
4 | Copyright (C) 2001-2013 Pierre Sarrazin <http://sarrazip.com/> | |
5 | 5 | |
6 | 6 | This program is free software; you can redistribute it and/or |
7 | 7 | modify it under the terms of the GNU General Public License |
3072 | 3072 | // |
3073 | 3073 | |
3074 | 3074 | |
3075 | int BurgerSpaceServer::savedGameFormatVersion = 1; | |
3076 | ||
3077 | ||
3078 | 3075 | string |
3079 | 3076 | BurgerSpaceServer::serialize(Couple c) const |
3080 | 3077 | { |
0 | /* $Id: BurgerSpaceServer.h,v 1.4 2010/12/31 04:58:16 sarrazip Exp $ | |
0 | /* $Id: BurgerSpaceServer.h,v 1.6 2013/02/25 05:04:43 sarrazip Exp $ | |
1 | 1 | BurgerSpaceServer.h - Main engine |
2 | 2 | |
3 | 3 | burgerspace - A hamburger-smashing video game. |
4 | Copyright (C) 2001-2010 Pierre Sarrazin <http://sarrazip.com/> | |
4 | Copyright (C) 2001-2013 Pierre Sarrazin <http://sarrazip.com/> | |
5 | 5 | |
6 | 6 | This program is free software; you can redistribute it and/or |
7 | 7 | modify it under the terms of the GNU General Public License |
333 | 333 | int numAvailablePeppers; // number of pepper shots available to player |
334 | 334 | |
335 | 335 | Level theCurrentLevel; |
336 | ||
337 | static int savedGameFormatVersion; | |
338 | 336 | |
339 | 337 | |
340 | 338 | /////////////////////////////////////////////////////////////////////////// |
0 | /* $Id: LocalServer.cpp,v 1.2 2010/05/26 03:13:01 sarrazip Exp $ | |
0 | /* $Id: LocalServer.cpp,v 1.4 2013/02/25 05:04:43 sarrazip Exp $ | |
1 | 1 | LocalServer.cpp - Direct function call server |
2 | 2 | |
3 | 3 | burgerspace - A hamburger-smashing video game. |
4 | Copyright (C) 2010 Pierre Sarrazin <http://sarrazip.com/> | |
4 | Copyright (C) 2001-2013 Pierre Sarrazin <http://sarrazip.com/> | |
5 | 5 | |
6 | 6 | This program is free software; you can redistribute it and/or |
7 | 7 | modify it under the terms of the GNU General Public License |
31 | 31 | bool |
32 | 32 | LocalServer::saveGame(ostream &out) |
33 | 33 | { |
34 | out << savedGameFormatVersion << "\n"; | |
34 | out << 2 << "\n"; // format version | |
35 | 35 | if (out.fail()) |
36 | 36 | return false; |
37 | 37 | out << "\n"; |
41 | 41 | << cumulLevelNo << "\n" |
42 | 42 | << tickCount << "\n" |
43 | 43 | << serialize(initPlayerPos) << "\n" |
44 | << serialize(*playerSprite) << "\n" | |
44 | << (playerSprite != NULL) << "\n" // new as of format version 2 | |
45 | << (playerSprite != NULL ? serialize(*playerSprite) : "") << "\n" | |
45 | 46 | << lastPlayerDirection << "\n" |
46 | 47 | << oldMotionMode << "\n" |
47 | 48 | ; |
112 | 113 | in >> version; |
113 | 114 | if (!in) |
114 | 115 | return -1; |
115 | if (version != savedGameFormatVersion) | |
116 | if (version != 1 && version != 2) | |
116 | 117 | return -2; |
117 | 118 | |
118 | 119 | in >> initLevelNo >> cumulLevelNo >> tickCount; |
125 | 126 | return -4; |
126 | 127 | |
127 | 128 | delete playerSprite; |
128 | playerSprite = deserializeSprite(in); | |
129 | if (playerSprite == NULL) | |
130 | return -5; | |
129 | playerSprite = NULL; | |
130 | int isPlayerSpritePresent = 1; | |
131 | if (version >= 2) | |
132 | { | |
133 | in >> isPlayerSpritePresent; | |
134 | if (!in) | |
135 | return -20; | |
136 | } | |
137 | if (isPlayerSpritePresent) | |
138 | { | |
139 | playerSprite = deserializeSprite(in); | |
140 | if (playerSprite == NULL) | |
141 | return -5; | |
142 | } | |
131 | 143 | |
132 | 144 | in >> lastPlayerDirection >> oldMotionMode; |
133 | 145 | if (!in) |
159 | 159 | DEFAULT_UDP_SERVER_PORT = @DEFAULT_UDP_SERVER_PORT@ |
160 | 160 | DEFS = @DEFS@ |
161 | 161 | DEPDIR = @DEPDIR@ |
162 | DLLTOOL = @DLLTOOL@ | |
162 | 163 | DSYMUTIL = @DSYMUTIL@ |
163 | 164 | DUMPBIN = @DUMPBIN@ |
164 | 165 | ECHO_C = @ECHO_C@ |
184 | 185 | LN_S = @LN_S@ |
185 | 186 | LTLIBOBJS = @LTLIBOBJS@ |
186 | 187 | MAKEINFO = @MAKEINFO@ |
188 | MANIFEST_TOOL = @MANIFEST_TOOL@ | |
187 | 189 | MANUAL_DATE_EN = @MANUAL_DATE_EN@ |
188 | 190 | MANUAL_DATE_FR = @MANUAL_DATE_FR@ |
189 | 191 | MINVER_FLATZEBRA = @MINVER_FLATZEBRA@ |
218 | 220 | abs_srcdir = @abs_srcdir@ |
219 | 221 | abs_top_builddir = @abs_top_builddir@ |
220 | 222 | abs_top_srcdir = @abs_top_srcdir@ |
223 | ac_ct_AR = @ac_ct_AR@ | |
221 | 224 | ac_ct_CC = @ac_ct_CC@ |
222 | 225 | ac_ct_CXX = @ac_ct_CXX@ |
223 | 226 | ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ |
0 | /* $Id: RemoteServer.cpp,v 1.4 2010/11/18 05:35:02 sarrazip Exp $ | |
0 | /* $Id: RemoteServer.cpp,v 1.5 2012/10/07 21:29:24 sarrazip Exp $ | |
1 | 1 | RemoteServer.cpp - UDP server |
2 | 2 | |
3 | 3 | burgerspace - A hamburger-smashing video game. |
31 | 31 | |
32 | 32 | #ifdef _MSC_VER |
33 | 33 | #include <io.h> // for close() |
34 | #else | |
35 | #include <unistd.h> // for close() | |
34 | 36 | #endif |
35 | 37 | |
36 | 38 |