# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
-## Copyright 1996, 1997, 1998, 1999, 2000, 2001
+## Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003
## Free Software Foundation, Inc.
## Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
##
## configuration script generated by Autoconf, you may include it under
## the same distribution terms that you use for the rest of that program.
-# serial 48 AC_PROG_LIBTOOL
+# serial 49 AC_PROG_LIBTOOL
# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
# Use C for the default configuration in the libtool script
AC_LIBTOOL_LANG_C_CONFIG
_LT_AC_TAG_CONFIG
+dnl _LT_CONFIG_COMMANDS
])# AC_LIBTOOL_SETUP
+
+
+## ------------------------------------- ##
+## Accumulate code for creating libtool. ##
+## ------------------------------------- ##
+
+# So that we can recreate a full libtool script including additional
+# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
+# in macros and then make a single call at the end using the `libtool'
+# label.
+
+# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
+# ----------------------------------------
+# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
+m4_define([_LT_CONFIG_LIBTOOL_INIT],
+[m4_ifval([$1],
+ [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
+ [$1
+])])])
+
+# Initialize.
+m4_define([_LT_OUTPUT_LIBTOOL_INIT])
+
+# _LT_CONFIG_LIBTOOL([COMMANDS])
+# ------------------------------
+# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
+m4_define([_LT_CONFIG_LIBTOOL],
+[m4_ifval([$1],
+ [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
+ [$1
+])])])
+
+# Initialize.
+m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
+
+# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
+# ---------------------------------------------------
+m4_define([_LT_CONFIG_SAVE_COMMANDS],
+[_LT_CONFIG_LIBTOOL([$1])
+_LT_CONFIG_LIBTOOL_INIT([$2])
+])
+
+# _LT_CONFIG_COMMANDS
+# -------------------
+# Send accumulated output to $CONFIG_STATUS.
+m4_define([_LT_CONFIG_COMMANDS],
+[AC_CONFIG_COMMANDS([libtool-bogus],
+ [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_INIT])
+])
+
+
+
# _LT_AC_SYS_COMPILER
# -------------------
AC_DEFUN([_LT_AC_SYS_COMPILER],
if test "X[$]1" = X--fallback-echo; then
# used as fallback echo
shift
- cat <<EOF
+ cat <<_LT_EOF
[$]*
-EOF
+_LT_EOF
exit 0
fi
else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<EOF
+ cat > conftest.$ac_ext <<_LT_EOF
[#line __oline__ "configure"
#include "confdefs.h"
exit (status);
}]
-EOF
+_LT_EOF
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
(./conftest; exit; ) 2>/dev/null
lt_status=$?
# _LT_AC_TAG_CONFIG
# -----------------
AC_DEFUN([_LT_AC_TAG_CONFIG],
-[AC_PROVIDE_IFELSE([AC_LIBTOOL_TAGS],,
- [AC_LIBTOOL_TAGS([CXX F77 GCJ RC])])
-
-if test -f "$ltmain"; then
- if test ! -f "${ofile}"; then
- AC_MSG_WARN([output file `$ofile' does not exist])
- fi
-
- if test -z "$LTCC"; then
- eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
- if test -z "$LTCC"; then
- AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
- else
- AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
- fi
- fi
-
- # Extract list of available tagged configurations in $ofile.
- # Note that this assumes the entire list is on one line.
- available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
-
+[AC_PROVIDE_IFELSE([AC_LIBTOOL_TAGS], [], [
+ AC_LIBTOOL_TAGS([CXX F77 GCJ RC])])dnl
+ available_tags=""
AC_FOREACH([_LT_TAG], _LT_TAGS,
[m4_case(_LT_TAG,
[CXX], [_LT_AC_TAG_CHECK([CXX])
- echo appending configuration tag \"CXX\" to $ofile
if test -n "$CXX" && test "X$CXX" != "Xno"; then
AC_LIBTOOL_LANG_CXX_CONFIG
available_tags="$available_tags _LT_TAG"
fi],
[F77], [_LT_AC_TAG_CHECK(_LT_TAG)
- echo appending configuration tag \"_LT_TAG\" to $ofile
if test -n "$F77" && test "X$F77" != "Xno"; then
AC_LIBTOOL_LANG_F77_CONFIG
available_tags="$available_tags _LT_TAG"
fi],
[GCJ], [_LT_AC_TAG_CHECK(_LT_TAG)
- echo appending configuration tag \"_LT_TAG\" to $ofile
if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
AC_LIBTOOL_LANG_GCJ_CONFIG
available_tags="$available_tags _LT_TAG"
fi],
[RC], [_LT_AC_TAG_CHECK(_LT_TAG)
- echo appending configuration tag \"_LT_TAG\" to $ofile
- AC_LIBTOOL_LANG_RC_CONFIG
- available_tags="$available_tags _LT_TAG"],
+ if test -n "$RC" && test "X$RC" != "Xno"; then
+ AC_LIBTOOL_LANG_RC_CONFIG
+ available_tags="$available_tags _LT_TAG"
+ fi],
[m4_errprintn(m4_location[: error: invalid tag name: ]"_LT_TAG")
m4_exit(1)])
])
- # Now substitute the updated list of available tags.
- if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
- mv "${ofile}T" "$ofile"
- chmod +x "$ofile"
- else
- rm -f "${ofile}T"
- AC_MSG_ERROR([unable to update list of available tagged configurations.])
- fi
-fi
+ AC_CONFIG_COMMANDS([libtool-tags], [
+ if test -f "$ltmain"; then
+ if test ! -f "${ofile}"; then
+ AC_MSG_ERROR([output file `$ofile' does not exist])
+ fi
+ if test -z "$LTCC"; then
+ eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
+ if test -z "$LTCC"; then
+ AC_MSG_ERROR([output file `$ofile' does not look like a libtool script])
+ else
+ AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
+ fi
+ fi
+
+ # Now substitute the updated list of available tags.
+ if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
+ mv "${ofile}T" "$ofile"
+ chmod +x "$ofile"
+ else
+ rm -f "${ofile}T"
+ AC_MSG_ERROR([unable to update list of available tagged configurations.])
+ fi
+ fi
+ ], [
+ libtool='$ofile'
+ available_tags='$available_tags'
+ ])dnl
])# _LT_AC_TAG_CONFIG
$EGREP "$file_magic_regex" > /dev/null; then
:
else
- cat <<EOF 1>&2
+ cat <<_LT_EOF 1>&2
*** Warning: the command libtool uses to detect shared libraries,
*** $file_magic_cmd, produces output that libtool cannot recognize.
*** may want to report the problem to your system manager and/or to
*** bug-libtool@gnu.org
-EOF
+_LT_EOF
fi ;;
esac
fi
lt_simple_link_test_code='int main(){return(0);}\n'
_LT_AC_SYS_COMPILER
+# Save the default compiler, since it gets overwritten when the other
+# tags are being tested, and _LT_AC_TAGVAR(compiler, []) is a NOP.
+compiler_DEFAULT=$CC
#
# Check for any special shared library compilation flags.
AC_LIBTOOL_SYS_LIB_STRIP
AC_LIBTOOL_DLOPEN_SELF($1)
-# Report which librarie types wil actually be built
+# Report which library types wil actually be built
AC_MSG_CHECKING([if libtool supports shared libraries])
AC_MSG_RESULT([$can_build_shared])
# Warning - without using the other runtime loading flags (-brtl),
# -berok will link without error, but may produce a broken library.
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
- # Determine the default libpath from the value encoded in an empty executable.
+ # Determine the default libpath from the value encoded in an empty
+ # executable.
_LT_AC_SYS_LIBPATH_AIX
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
else
- # Determine the default libpath from the value encoded in an empty executable.
+ # Determine the default libpath from the value encoded in an
+ # empty executable.
_LT_AC_SYS_LIBPATH_AIX
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
# Warning - without using the other run time loading flags,
dnl not a library. It's possible we should let each
dnl tag define a new lt_????_link_test_code variable,
dnl but it's only used here...
-ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
+ifelse([$1],[],[cat > conftest.$ac_ext <<_LT_EOF
int a;
void foo (void) { a = 0; }
-EOF
-],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
+_LT_EOF
+],[$1],[CXX],[cat > conftest.$ac_ext <<_LT_EOF
class Foo
{
public:
private:
int a;
};
-EOF
-],[$1],[F77],[cat > conftest.$ac_ext <<EOF
+_LT_EOF
+],[$1],[F77],[cat > conftest.$ac_ext <<_LT_EOF
subroutine foo
implicit none
integer*4 a
a=0
return
end
-EOF
-],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
+_LT_EOF
+],[$1],[GCJ],[cat > conftest.$ac_ext <<_LT_EOF
public class foo {
private int a;
public void bar (void) {
a = 0;
}
};
-EOF
+_LT_EOF
])
dnl Parse the compiler output and extract the necessary
dnl objects, libraries and library flags.
# add code to config.status for appending the configuration named by
# TAGNAME from the matching tagged config vars.
AC_DEFUN([AC_LIBTOOL_CONFIG],
-[# The else clause should only fire when bootstrapping the
-# libtool distribution, otherwise you forgot to ship ltmain.sh
-# with your package, and you will get complaints that there are
-# no rules to generate ltmain.sh.
-if test -f "$ltmain"; then
- # See if we are running on zsh, and set the options which allow our commands through
- # without removal of \ escapes.
+[AC_CONFIG_COMMANDS([libtool]$1, [
+ # See if we are running on zsh, and set the options which allow our
+ # commands through without removal of \ escapes.
if test -n "${ZSH_VERSION+set}" ; then
setopt NO_GLOB_SUBST
fi
- # Now quote all the things that may contain metacharacters while being
- # careful not to overquote the AC_SUBSTed values. We take copies of the
- # variables and quote the copies for generation of the libtool script.
- for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM SED SHELL STRIP \
- libname_spec library_names_spec soname_spec extract_expsyms_cmds \
- old_striplib striplib file_magic_cmd finish_cmds finish_eval \
- deplibs_check_method reload_flag reload_cmds need_locks \
- lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
- lt_cv_sys_global_symbol_to_c_name_address \
- sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
- old_postinstall_cmds old_postuninstall_cmds \
- _LT_AC_TAGVAR(compiler, $1) \
- _LT_AC_TAGVAR(CC, $1) \
- _LT_AC_TAGVAR(LD, $1) \
- _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
- _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
- _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
- _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
- _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
- _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
- _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
- _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
- _LT_AC_TAGVAR(old_archive_cmds, $1) \
- _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
- _LT_AC_TAGVAR(predep_objects, $1) \
- _LT_AC_TAGVAR(postdep_objects, $1) \
- _LT_AC_TAGVAR(predeps, $1) \
- _LT_AC_TAGVAR(postdeps, $1) \
- _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
- _LT_AC_TAGVAR(archive_cmds, $1) \
- _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
- _LT_AC_TAGVAR(postinstall_cmds, $1) \
- _LT_AC_TAGVAR(postuninstall_cmds, $1) \
- _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
- _LT_AC_TAGVAR(allow_undefined_flag, $1) \
- _LT_AC_TAGVAR(no_undefined_flag, $1) \
- _LT_AC_TAGVAR(export_symbols_cmds, $1) \
- _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
- _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
- _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
- _LT_AC_TAGVAR(hardcode_automatic, $1) \
- _LT_AC_TAGVAR(module_cmds, $1) \
- _LT_AC_TAGVAR(module_expsym_cmds, $1) \
- _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
- _LT_AC_TAGVAR(exclude_expsyms, $1) \
- _LT_AC_TAGVAR(include_expsyms, $1); do
-
- case $var in
- _LT_AC_TAGVAR(old_archive_cmds, $1) | \
- _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
- _LT_AC_TAGVAR(archive_cmds, $1) | \
- _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
- _LT_AC_TAGVAR(module_cmds, $1) | \
- _LT_AC_TAGVAR(module_expsym_cmds, $1) | \
- _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
- _LT_AC_TAGVAR(export_symbols_cmds, $1) | \
- extract_expsyms_cmds | reload_cmds | finish_cmds | \
- postinstall_cmds | postuninstall_cmds | \
- old_postinstall_cmds | old_postuninstall_cmds | \
- sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
- # Double-quote double-evaled strings.
- eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
- ;;
- *)
- eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
- ;;
- esac
- done
- case $lt_echo in
- *'\[$]0 --fallback-echo"')
- lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
- ;;
- esac
-
-ifelse([$1], [],
- [cfgfile="${ofile}T"
- trap "$rm \"$cfgfile\"; exit 1" 1 2 15
- $rm -f "$cfgfile"
- AC_MSG_NOTICE([creating $ofile])],
- [cfgfile="$ofile"])
+ ifelse([$1], [],
+ [cfgfile="${ofile}T"
+ trap "$rm \"$cfgfile\"; exit 1" 1 2 15
+ $rm -f "$cfgfile"
+ AC_MSG_NOTICE([creating $ofile])],
+ [cfgfile="$ofile"
+ AC_MSG_NOTICE([appending configuration tag `$1' to $ofile])
+ ])
- cat <<__EOF__ >> "$cfgfile"
+ cat <<_LT_EOF >> "$cfgfile"
ifelse([$1], [],
[#! $SHELL
[# ### END LIBTOOL CONFIG],
[# ### END LIBTOOL TAG CONFIG: $1])
-__EOF__
+_LT_EOF
ifelse([$1],[], [
case $host_os in
aix3*)
- cat <<\EOF >> "$cfgfile"
+ cat <<\_LT_EOF >> "$cfgfile"
# AIX sometimes has problems with the GCC collect2 program. For some
# reason, if we set the COLLECT_NAMES environment variable, the problems
COLLECT_NAMES=
export COLLECT_NAMES
fi
-EOF
+_LT_EOF
;;
esac
(rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
chmod +x "$ofile"
])
-else
- # If there is no Makefile yet, we rely on a make rule to execute
- # `config.status --recheck' to rerun these tests and create the
- # libtool script then.
- test -f Makefile && make "$ltmain"
-fi
+],
+[ifelse([$1], [], [
+ rm="$rm"
+ PACKAGE="$PACKAGE"
+ VERSION="$VERSION"
+ TIMESTAMP="$TIMESTAMP"
+ ltmain="$ltmain"
+ ofile="$ofile"
+ sed_quote_subst='$sed_quote_subst'
+ double_quote_subst='$double_quote_subst'
+ delay_variable_subst='$delay_variable_subst'
+ SED="$SED"
+ Xsed="$Xsed"
+
+ SHELL='$SHELL'
+ enable_shared='$enable_shared'
+ enable_static='$enable_static'
+ enable_fast_install='$enable_fast_install'
+ host_alias='$host_alias'
+ host='$host'
+ echo='$echo'
+ AR='$AR'
+ AR_FLAGS='$AR_FLAGS'
+ LTCC='$LTCC'
+ EGREP='$EGREP'
+ LN_S='$LN_S'
+ NM='$NM'
+ STRIP='$STRIP'
+ MAGIC_CMD='$MAGIC_CMD'
+ DLLTOOL='$DLLTOOL'
+ OBJDUMP='$OBJDUMP'
+ AS='$AS'
+ objdir='$objdir'
+ reload_flag='$reload_flag'
+ reload_cmds='$reload_cmds'
+ ac_objext='$ac_objext'
+ libext='$libext'
+ shrext='$shrext'
+ exeext='$exeext'
+ pic_mode='$pic_mode'
+ lt_cv_sys_max_cmd_len='$lt_cv_sys_max_cmd_len'
+ need_locks='$need_locks'
+ need_lib_prefix='$need_lib_prefix'
+ need_version='$need_version'
+ enable_dlopen='$enable_dlopen'
+ enable_dlopen_self='$enable_dlopen_self'
+ enable_dlopen_self_static='$enable_dlopen_self_static'
+ version_type='$version_type'
+ libname_spec='$libname_spec'
+ library_names_spec='$library_names_spec'
+ soname_spec='$soname_spec'
+ RANLIB='$RANLIB'
+ old_postinstall_cmds='$old_postinstall_cmds'
+ old_postuninstall_cmds='$old_postuninstall_cmds'
+ postinstall_cmds='$postinstall_cmds'
+ postuninstall_cmds='$postuninstall_cmds'
+ striplib='$striplib'
+ old_striplib='$old_striplib'
+ deplibs_check_method='$deplibs_check_method'
+ file_magic_cmd='$file_magic_cmd'
+ finish_cmds='$finish_cmds'
+ finish_eval='$finish_eval'
+ lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe"
+ lt_cv_sys_global_symbol_to_cdecl="$lt_cv_sys_global_symbol_to_cdecl"
+ lt_cv_sys_global_symbol_to_c_name_address=`echo "X$lt_cv_sys_global_symbol_to_c_name_address" | $Xsed -e "$sed_quote_subst" -e 's,^,",;s,$,",'`
+ runpath_var='$runpath_var'
+ shlibpath_var='$shlibpath_var'
+ hardcode_into_libs='$hardcode_into_libs'
+ shlibpath_overrides_runpath='$shlibpath_overrides_runpath'
+ variables_saved_for_relink='$variables_saved_for_relink'
+ sys_lib_search_path_spec='$sys_lib_search_path_spec'
+ sys_lib_dlsearch_path_spec='$sys_lib_dlsearch_path_spec'
+ extract_expsyms_cmds='$extract_expsyms_cmds'
+
+ dnl ## --------------------------------------- ##
+ dnl ## Carefully restore the default compiler. ##
+ dnl ## --------------------------------------- ##
+ compiler='$compiler_DEFAULT'],
+ [_LT_AC_TAGVAR(compiler, $1)='$_LT_AC_TAGVAR(compiler, $1)'])
+ _LT_AC_TAGVAR(archive_cmds_need_lc, $1)='$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)'
+ _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)='$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)'
+ _LT_AC_TAGVAR(GCC, $1)='$_LT_AC_TAGVAR(GCC, $1)'
+ _LT_AC_TAGVAR(LD, $1)='$_LT_AC_TAGVAR(LD, $1)'
+ _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)'
+ _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)'
+ _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)='$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)'
+ _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)'
+ _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)='$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)'
+ _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='$_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)'
+ _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$_LT_AC_TAGVAR(whole_archive_flag_spec, $1)'
+ _LT_AC_TAGVAR(thread_safe_flag_spec, $1)='$_LT_AC_TAGVAR(thread_safe_flag_spec, $1)'
+ _LT_AC_TAGVAR(old_archive_cmds, $1)='$_LT_AC_TAGVAR(old_archive_cmds, $1)'
+ _LT_AC_TAGVAR(old_archive_from_new_cmds, $1)='$_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)'
+ _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)='$_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)'
+ _LT_AC_TAGVAR(archive_cmds, $1)='$_LT_AC_TAGVAR(archive_cmds, $1)'
+ _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$_LT_AC_TAGVAR(archive_expsym_cmds, $1)'
+ _LT_AC_TAGVAR(module_cmds, $1)='$_LT_AC_TAGVAR(module_cmds, $1)'
+ _LT_AC_TAGVAR(module_expsym_cmds, $1)='$_LT_AC_TAGVAR(module_expsym_cmds, $1)'
+ _LT_AC_TAGVAR(predep_objects, $1)='$_LT_AC_TAGVAR(predep_objects, $1)'
+ _LT_AC_TAGVAR(postdep_objects, $1)='$_LT_AC_TAGVAR(postdep_objects, $1)'
+ _LT_AC_TAGVAR(predeps, $1)='$_LT_AC_TAGVAR(predeps, $1)'
+ _LT_AC_TAGVAR(postdeps, $1)='$_LT_AC_TAGVAR(postdeps, $1)'
+ _LT_AC_TAGVAR(compiler_lib_search_path, $1)='$_LT_AC_TAGVAR(compiler_lib_search_path, $1)'
+ _LT_AC_TAGVAR(allow_undefined_flag, $1)='$_LT_AC_TAGVAR(allow_undefined_flag, $1)'
+ _LT_AC_TAGVAR(no_undefined_flag, $1)='$_LT_AC_TAGVAR(no_undefined_flag, $1)'
+ _LT_AC_TAGVAR(hardcode_action, $1)='$_LT_AC_TAGVAR(hardcode_action, $1)'
+ _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)'
+ _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='$_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)'
+ _LT_AC_TAGVAR(hardcode_libdir_separator, $1)='$_LT_AC_TAGVAR(hardcode_libdir_separator, $1)'
+ _LT_AC_TAGVAR(hardcode_direct, $1)='$_LT_AC_TAGVAR(hardcode_direct, $1)'
+ _LT_AC_TAGVAR(hardcode_minus_L, $1)='$_LT_AC_TAGVAR(hardcode_minus_L, $1)'
+ _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)='$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)'
+ _LT_AC_TAGVAR(hardcode_automatic, $1)='$_LT_AC_TAGVAR(hardcode_automatic, $1)'
+ _LT_AC_TAGVAR(link_all_deplibs, $1)='$_LT_AC_TAGVAR(link_all_deplibs, $1)'
+ _LT_AC_TAGVAR(fix_srcfile_path, $1)='$_LT_AC_TAGVAR(fix_srcfile_path, $1)'
+ _LT_AC_TAGVAR(always_export_symbols, $1)='$_LT_AC_TAGVAR(always_export_symbols, $1)'
+ _LT_AC_TAGVAR(export_symbols_cmds, $1)=`echo "$_LT_AC_TAGVAR(export_symbols_cmds, $1)" | $Xsed -e "$sed_quote_subst" -e 's,^,",;s,$,",'`
+ _LT_AC_TAGVAR(exclude_expsyms, $1)='$_LT_AC_TAGVAR(exclude_expsyms, $1)'
+ _LT_AC_TAGVAR(include_expsyms, $1)='$_LT_AC_TAGVAR(include_expsyms, $1)'
+
+
+ # Now quote all the things that may contain metacharacters while being
+ # careful not to overquote the AC_SUBSTed values. We take copies of the
+ # variables and quote the copies for generation of the libtool script.
+ for var in ifelse([$1], [],
+ [SED SHELL echo AR AR_FLAGS LTCC EGREP RANLIB LN_S NM STRIP \
+ libname_spec library_names_spec soname_spec extract_expsyms_cmds \
+ old_striplib striplib file_magic_cmd finish_cmds finish_eval \
+ deplibs_check_method reload_flag reload_cmds need_locks \
+ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
+ lt_cv_sys_global_symbol_to_c_name_address \
+ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
+ old_postinstall_cmds old_postuninstall_cmds \
+])dnl
+ _LT_AC_TAGVAR(compiler, $1) \
+ _LT_AC_TAGVAR(CC, $1) \
+ _LT_AC_TAGVAR(LD, $1) \
+ _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
+ _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
+ _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
+ _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
+ _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
+ _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
+ _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
+ _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
+ _LT_AC_TAGVAR(old_archive_cmds, $1) \
+ _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
+ _LT_AC_TAGVAR(predep_objects, $1) \
+ _LT_AC_TAGVAR(postdep_objects, $1) \
+ _LT_AC_TAGVAR(predeps, $1) \
+ _LT_AC_TAGVAR(postdeps, $1) \
+ _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
+ _LT_AC_TAGVAR(archive_cmds, $1) \
+ _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
+ _LT_AC_TAGVAR(postinstall_cmds, $1) \
+ _LT_AC_TAGVAR(postuninstall_cmds, $1) \
+ _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
+ _LT_AC_TAGVAR(allow_undefined_flag, $1) \
+ _LT_AC_TAGVAR(no_undefined_flag, $1) \
+ _LT_AC_TAGVAR(export_symbols_cmds, $1) \
+ _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
+ _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
+ _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
+ _LT_AC_TAGVAR(hardcode_automatic, $1) \
+ _LT_AC_TAGVAR(module_cmds, $1) \
+ _LT_AC_TAGVAR(module_expsym_cmds, $1) \
+ _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
+ _LT_AC_TAGVAR(exclude_expsyms, $1) \
+ _LT_AC_TAGVAR(include_expsyms, $1); do
+
+ case \$var in \
+ _LT_AC_TAGVAR(old_archive_cmds, $1) | \
+ _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
+ _LT_AC_TAGVAR(archive_cmds, $1) | \
+ _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
+ _LT_AC_TAGVAR(module_cmds, $1) | \
+ _LT_AC_TAGVAR(module_expsym_cmds, $1) | \
+ _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
+ _LT_AC_TAGVAR(export_symbols_cmds, $1) | \
+ extract_expsyms_cmds | reload_cmds | finish_cmds | \
+ postinstall_cmds | postuninstall_cmds | \
+ old_postinstall_cmds | old_postuninstall_cmds | \
+ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
+ # Double-quote double-evaled strings.
+ eval "lt_\$var=\\\\\"\\\`\\\$echo \"X\\\$\$var\" | \\\$Xsed -e \"\\\$double_quote_subst\" -e \"\\\$sed_quote_subst\" -e \"\\\$delay_variable_subst\"\\\`\\\\\""
+ ;;
+ *)
+ eval "lt_\$var=\\\\\"\\\`\\\$echo \"X\\\$\$var\" | \\\$Xsed -e \"\\\$sed_quote_subst\"\\\`\\\\\""
+ ;;
+ esac
+ done
+
+ case \$lt_echo in
+ *'\\\[$]0 --fallback-echo"')
+ lt_echo=\`\$echo "X\$lt_echo" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\`
+ ;;
+ esac
+])
])# AC_LIBTOOL_CONFIG
pipe_works=no
rm -f conftest*
- cat > conftest.$ac_ext <<EOF
+ cat > conftest.$ac_ext <<_LT_EOF
#ifdef __cplusplus
extern "C" {
#endif
}
#endif
int main(){nm_test_var='a';nm_test_func();return(0);}
-EOF
+_LT_EOF
if AC_TRY_EVAL(ac_compile); then
# Now try to grab the symbols.
# Make sure that we snagged all the symbols we need.
if grep ' nm_test_var$' "$nlist" >/dev/null; then
if grep ' nm_test_func$' "$nlist" >/dev/null; then
- cat <<EOF > conftest.$ac_ext
+ cat <<_LT_EOF > conftest.$ac_ext
#ifdef __cplusplus
extern "C" {
#endif
-EOF
+_LT_EOF
# Now generate the symbol file.
eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
- cat <<EOF >> conftest.$ac_ext
+ cat <<_LT_EOF >> conftest.$ac_ext
#if defined (__STDC__) && __STDC__
# define lt_ptr_t void *
#else
}
lt_preloaded_symbols[[]] =
{
-EOF
+_LT_EOF
$SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
- cat <<\EOF >> conftest.$ac_ext
+ cat <<\_LT_EOF >> conftest.$ac_ext
{0, (lt_ptr_t) 0}
};
#ifdef __cplusplus
}
#endif
-EOF
+_LT_EOF
# Now try linking the two files.
mv conftest.$ac_objext conftstm.$ac_objext
lt_save_LIBS="$LIBS"
# On AIX/PPC, the GNU linker is very broken
if test "$host_cpu" != ia64; then
_LT_AC_TAGVAR(ld_shlibs, $1)=no
- cat <<EOF 1>&2
+ cat <<_LT_EOF 1>&2
*** Warning: the GNU linker, at least up to release 2.9.1, is reported
*** to be unable to reliably create shared libraries on AIX.
*** really care for shared libraries, you may want to modify your PATH
*** so that a non-GNU linker is found, and then restart.
-EOF
+_LT_EOF
fi
;;
solaris* | sysv5*)
if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
_LT_AC_TAGVAR(ld_shlibs, $1)=no
- cat <<EOF 1>&2
+ cat <<_LT_EOF 1>&2
*** Warning: The releases 2.8.* of the GNU linker cannot reliably
*** create shared libraries on Solaris systems. Therefore, libtool
*** your PATH or compiler configuration so that the native linker is
*** used, and then restart.
-EOF
+_LT_EOF
elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
# Warning - without using the other runtime loading flags (-brtl),
# -berok will link without error, but may produce a broken library.
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
- # Determine the default libpath from the value encoded in an empty executable.
+ # Determine the default libpath from the value encoded in an
+ # empty executable.
_LT_AC_SYS_LIBPATH_AIX
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
- else
+ else
if test "$host_cpu" = ia64; then
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
else
- # Determine the default libpath from the value encoded in an empty executable.
+ # Determine the default libpath from the value encoded in an
+ # empty executable.
_LT_AC_SYS_LIBPATH_AIX
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
# Warning - without using the other run time loading flags,