# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
+echo=echo
+if test X`$echo '\t'` = 'X\t'; then :
+else
+ # The Solaris and AIX default echo program unquotes backslashes.
+ # This makes it impossible to quote backslashes using
+ # echo "$something" | sed 's/\\/\\\\/g'
+ # So, we emulate echo with printf '%s\n'
+ echo='printf %s\n'
+ if test X`$echo '\t'` = 'X\t'; then :
+ else
+ # Oops. We have no working printf. Try to find a not-so-buggy echo.
+ echo=echo
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
+ save_PATH="$PATH"
+ PATH="$PATH":/usr/ucb
+ for dir in $PATH; do
+ if test -f $dir/echo && test X`$dir/echo '\t'` = 'X\t'; then
+ echo="$dir/echo"
+ break
+ fi
+ done
+ IFS="$save_ifs"
+ PATH="$save_PATH"
+ fi
+fi
+
# The name of this program.
-progname=`echo "$0" | sed 's%^.*/%%'`
+progname=`$echo "$0" | sed 's%^.*/%%'`
# Constants.
PROGRAM=ltmain.sh
if test "${LANG+set}" = set; then LANG=C; export LANG; fi
if test "$LTCONFIG_VERSION" != "$VERSION"; then
- echo "$progname: ltconfig version \`$LTCONFIG_VERSION' does not match $PROGRAM version \`$VERSION'" 1>&2
- echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2
+ $echo "$progname: ltconfig version \`$LTCONFIG_VERSION' does not match $PROGRAM version \`$VERSION'" 1>&2
+ $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2
exit 1
fi
#
if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then
- echo "$progname: not configured to build any kind of library" 1>&2
- echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2
+ $echo "$progname: not configured to build any kind of library" 1>&2
+ $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2
exit 1
fi
prev=
prevopt=
run=
-show=echo
+show="$echo"
show_help=
execute_dlfiles=
shift
case "$arg" in
- -*=*) optarg=`echo "$arg" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
+ -*=*) optarg=`$echo "$arg" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
*) optarg= ;;
esac
;;
--version)
- echo "$PROGRAM (GNU $PACKAGE) $VERSION"
+ $echo "$PROGRAM (GNU $PACKAGE) $VERSION"
exit 0
;;
;;
--features)
- echo "host: $host"
+ $echo "host: $host"
if test "$build_libtool_libs" = yes; then
- echo "enable shared libraries"
+ $echo "enable shared libraries"
else
- echo "disable shared libraries"
+ $echo "disable shared libraries"
fi
if test "$build_old_libs" = yes; then
- echo "enable static libraries"
+ $echo "enable static libraries"
else
- echo "disable static libraries"
+ $echo "disable static libraries"
fi
exit 0
;;
;;
-*)
- echo "$progname: unrecognized option \`$arg'" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: unrecognized option \`$arg'" 1>&2
+ $echo "$help" 1>&2
exit 1
;;
done
if test -n "$prevopt"; then
- echo "$progname: option \`$prevopt' requires an argument" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: option \`$prevopt' requires an argument" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
# Just use the default operation mode.
if test -z "$mode"; then
if test -n "$nonopt"; then
- echo "$progname: warning: cannot infer operation mode from \`$nonopt'" 1>&2
+ $echo "$progname: warning: cannot infer operation mode from \`$nonopt'" 1>&2
else
- echo "$progname: warning: cannot infer operation mode without MODE-ARGS" 1>&2
+ $echo "$progname: warning: cannot infer operation mode without MODE-ARGS" 1>&2
fi
fi
;;
# Only execute mode is allowed to have -dlopen flags.
if test -n "$execute_dlfiles" && test "$mode" != execute; then
- echo "$progname: unrecognized option \`-dlopen'" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: unrecognized option \`-dlopen'" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
do
# The only flag that cannot be specified is the output filename.
if test "X$arg" = "X-o"; then
- echo "$progname: you cannot specify the output filename with \`-o'" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: you cannot specify the output filename with \`-o'" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
# Backslashify any backslashes, double quotes, and dollar signs.
# These are the only characters that are still specially
# interpreted inside of double-quoted scrings.
- lastarg=`echo "$lastarg" | sed "$sed_quote_subst"`
+ lastarg=`$echo "$lastarg" | sed "$sed_quote_subst"`
# Double-quote args containing other shell metacharacters.
# Many Bourne shells cannot handle close brackets correctly in scan
done
# Get the name of the library object.
- libobj=`echo "$srcfile" | sed -e 's%^.*/%%'`
+ libobj=`$echo "$srcfile" | sed -e 's%^.*/%%'`
# Recognize several different file suffixes.
xform='[cCFSfm]'
*.for) xform=for ;;
esac
- libobj=`echo "$libobj" | sed -e "s/\.$xform$/.lo/"`
+ libobj=`$echo "$libobj" | sed -e "s/\.$xform$/.lo/"`
case "$libobj" in
- *.lo) obj=`echo "$libobj" | sed -e 's/\.lo$/.o/'` ;;
+ *.lo) obj=`$echo "$libobj" | sed -e 's/\.lo$/.o/'` ;;
*)
- echo "$progname: cannot determine name of library object from \`$srcfile'" 1>&2
+ $echo "$progname: cannot determine name of library object from \`$srcfile'" 1>&2
exit 1
;;
esac
if test -z "$base_compile"; then
- echo "$progname: you must specify a compilation command" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: you must specify a compilation command" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
# Create an invalid libtool object if no PIC, so that we don't accidentally
# link it into a program.
if test "$build_libtool_libs" != yes; then
- $show "echo timestamp > $libobj"
- $run eval "echo timestamp > \$libobj" || exit $?
+ $show "$echo timestamp > $libobj"
+ $run eval "$echo timestamp > \$libobj" || exit $?
fi
exit 0
-static)
if test "$build_libtool_libs" = yes; then
if test "$hardcode_direct" = unsupported && test -z "$link_static_flag"; then
- echo "$progname: warning: static linking is impossible in this configuration" 1>&2
+ $echo "$progname: warning: static linking is impossible in this configuration" 1>&2
else
build_libtool_libs=no
fi
-export-dynamic)
if test "$export_dynamic" != yes; then
export_dynamic=yes
- arg=`eval echo "$export_dynamic_flag_spec"`
+ arg=`eval $echo "$export_dynamic_flag_spec"`
# Add the symbol object into the linking commands.
compile_command="$compile_command @SYMFILE@"
;;
-L*)
- dir=`echo "$arg" | sed 's%^-L\(.*\)$%\1%'`
+ dir=`$echo "$arg" | sed 's%^-L\(.*\)$%\1%'`
case "$dir" in
/*)
;;
*)
- echo "$progname: \`-L$dir' cannot specify a relative directory" 1>&2
+ $echo "$progname: \`-L$dir' cannot specify a relative directory" 1>&2
exit 1
;;
esac
-*)
# Unknown arguments in both finalize_command and compile_command need
# to be aesthetically quoted because they are evaled later.
- arg=`echo "$arg" | sed "$sed_quote_subst"`
+ arg=`$echo "$arg" | sed "$sed_quote_subst"`
case "$arg" in
*[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*)
arg="\"$arg\""
if test "$prev" = dlprefiles; then
# Preload the old-style object.
- dlprefiles="$dlprefiles "`echo "$arg" | sed 's/\.lo$/\.o/'`
+ dlprefiles="$dlprefiles "`$echo "$arg" | sed 's/\.lo$/\.o/'`
prev=
fi
libobjs="$libobjs $arg"
# Check to see that this really is a libtool archive.
if egrep "^# Generated by ltmain.sh" $arg >/dev/null 2>&1; then :
else
- echo "$progname: \`$arg' is not a valid libtool archive" 1>&2
+ $echo "$progname: \`$arg' is not a valid libtool archive" 1>&2
exit 1
fi
esac
if test -z "$libdir"; then
- echo "$progname: \`$arg' contains no -rpath information" 1>&2
+ $echo "$progname: \`$arg' contains no -rpath information" 1>&2
exit 1
fi
done
if test -z "$linklib"; then
- echo "$progname: cannot find name of link library for \`$arg'" 1>&2
+ $echo "$progname: cannot find name of link library for \`$arg'" 1>&2
exit 1
fi
# Find the relevant object directory and library name.
- name=`echo "$arg" | sed -e 's%^.*/%%' -e 's/\.la$//' -e 's/^lib//'`
- dir=`echo "$arg" | sed 's%/[^/]*$%%'`
+ name=`$echo "$arg" | sed -e 's%^.*/%%' -e 's/\.la$//' -e 's/^lib//'`
+ dir=`$echo "$arg" | sed 's%/[^/]*$%%'`
if test "X$dir" = "X$arg"; then
dir="$objdir"
else
fi
if test -n "$libdir"; then
- flag=`eval echo \"$hardcode_libdir_flag_spec\"`
+ flag=`eval $echo \"$hardcode_libdir_flag_spec\"`
compile_command="$compile_command $flag"
finalize_command="$finalize_command $flag"
*)
absdir=`cd "$dir" && pwd`
if test -z "$absdir"; then
- echo "$progname: cannot determine absolute directory name of \`$dir'" 1>&2
+ $echo "$progname: cannot determine absolute directory name of \`$dir'" 1>&2
exit 1
fi
dir="$absdir"
;;
*)
- echo "$progname: \`$hardcode_action' is an unknown hardcode action" 1>&2
+ $echo "$progname: \`$hardcode_action' is an unknown hardcode action" 1>&2
exit 1
;;
esac
else
# Transform directly to old archives if we don't build new libraries.
if test -n "$pic_flag" && test -z "$old_library"; then
- echo "$progname: cannot find static library for \`$arg'" 1>&2
+ $echo "$progname: cannot find static library for \`$arg'" 1>&2
exit 1
fi
;;
*)
- echo "$progname: unknown file suffix for \`$arg'" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: unknown file suffix for \`$arg'" 1>&2
+ $echo "$help" 1>&2
exit 1
;;
esac
done
if test -n "$prev"; then
- echo "$progname: the \`$prevarg' option requires an argument" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: the \`$prevarg' option requires an argument" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
# Substitute the hardcoded libdirs into the compile commands.
if test -n "$hardcode_libdir_separator"; then
- compile_command=`echo "$compile_command" | sed "s%@HARDCODE_LIBDIRS@%$hardcode_libdirs%g"`
- finalize_command=`echo "$finalize_command" | sed "s%@HARDCODE_LIBDIRS@%$hardcode_libdirs%g"`
+ compile_command=`$echo "$compile_command" | sed "s%@HARDCODE_LIBDIRS@%$hardcode_libdirs%g"`
+ finalize_command=`$echo "$finalize_command" | sed "s%@HARDCODE_LIBDIRS@%$hardcode_libdirs%g"`
fi
oldlib=
oldobjs=
case "$output" in
"")
- echo "$progname: you must specify an output file" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: you must specify an output file" 1>&2
+ $echo "$help" 1>&2
exit 1
;;
*/*)
- echo "$progname: output file \`$output' must have no directory components" 1>&2
+ $echo "$progname: output file \`$output' must have no directory components" 1>&2
exit 1
;;
*.la)
- libname=`echo "$output" | sed 's/\.la$//'`
+ libname=`$echo "$output" | sed 's/\.la$//'`
# All the library-specific variables (install_libdir is set above).
library_names=
age=0
if test -n "$objs"; then
- echo "$progname: cannot build libtool library \`$output' from non-libtool objects:$objs" 2>&1
+ $echo "$progname: cannot build libtool library \`$output' from non-libtool objects:$objs" 2>&1
exit 1
fi
# How the heck are we supposed to write a wrapper for a shared library?
if test -n "$link_against_libtool_libs"; then
- echo "$progname: libtool library \`$output' may not depend on uninstalled libraries:$link_against_libtool_libs" 1>&2
+ $echo "$progname: libtool library \`$output' may not depend on uninstalled libraries:$link_against_libtool_libs" 1>&2
exit 1
fi
if test -n "$dlfiles$dlprefiles"; then
- echo "$progname: warning: \`-dlopen' is ignored while creating libtool libraries" 1>&2
+ $echo "$progname: warning: \`-dlopen' is ignored while creating libtool libraries" 1>&2
# Nullify the symbol file.
- compile_command=`echo "$compile_command" | sed "s% @SYMFILE@%%"`
- finalize_command=`echo "$finalize_command" | sed "s% @SYMFILE@%%"`
+ compile_command=`$echo "$compile_command" | sed "s% @SYMFILE@%%"`
+ finalize_command=`$echo "$finalize_command" | sed "s% @SYMFILE@%%"`
fi
if test -z "$install_libdir"; then
- echo "$progname: you must specify an installation directory with \`-rpath'" 1>&2
+ $echo "$progname: you must specify an installation directory with \`-rpath'" 1>&2
exit 1
fi
# Parse the version information argument.
- IFS="${IFS= }"; save_ifs="$IFS"; IFS=':'
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS=':'
set dummy $vinfo
IFS="$save_ifs"
if test -n "$5"; then
- echo "$progname: too many parameters to \`-version-info'" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: too many parameters to \`-version-info'" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
case "$current" in
0 | [1-9] | [1-9][0-9]*) ;;
*)
- echo "$progname: CURRENT \`$current' is not a nonnegative integer" 1>&2
- echo "$progname: \`$vinfo' is not valid version information" 1>&2
+ $echo "$progname: CURRENT \`$current' is not a nonnegative integer" 1>&2
+ $echo "$progname: \`$vinfo' is not valid version information" 1>&2
exit 1
;;
esac
case "$revision" in
0 | [1-9] | [1-9][0-9]*) ;;
*)
- echo "$progname: REVISION \`$revision' is not a nonnegative integer" 1>&2
- echo "$progname: \`$vinfo' is not valid version information" 1>&2
+ $echo "$progname: REVISION \`$revision' is not a nonnegative integer" 1>&2
+ $echo "$progname: \`$vinfo' is not valid version information" 1>&2
exit 1
;;
esac
case "$age" in
0 | [1-9] | [1-9][0-9]*) ;;
*)
- echo "$progname: AGE \`$age' is not a nonnegative integer" 1>&2
- echo "$progname: \`$vinfo' is not valid version information" 1>&2
+ $echo "$progname: AGE \`$age' is not a nonnegative integer" 1>&2
+ $echo "$progname: \`$vinfo' is not valid version information" 1>&2
exit 1
;;
esac
if test $age -gt $current; then
- echo "$progname: AGE \`$age' is greater than the current interface number \`$current'" 1>&2
- echo "$progname: \`$vinfo' is not valid version information" 1>&2
+ $echo "$progname: AGE \`$age' is greater than the current interface number \`$current'" 1>&2
+ $echo "$progname: \`$vinfo' is not valid version information" 1>&2
exit 1
fi
;;
*)
- echo "$progname: unknown library version type \`$version_type'" 1>&2
- echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2
+ $echo "$progname: unknown library version type \`$version_type'" 1>&2
+ $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2
exit 1
;;
esac
# Check to see if the archive will have undefined symbols.
if test "$allow_undefined" = yes; then
if test "$allow_undefined_flag" = unsupported; then
- echo "$progname: warning: undefined symbols not allowed in $host shared libraries" 1>&2
+ $echo "$progname: warning: undefined symbols not allowed in $host shared libraries" 1>&2
build_libtool_libs=no
build_old_libs=yes
fi
if test "$build_libtool_libs" = yes; then
# Get the real and link names of the library.
- library_names=`eval echo \"$library_names_spec\"`
+ library_names=`eval $echo \"$library_names_spec\"`
set dummy $library_names
realname="$2"
shift; shift
if test -n "$soname_spec"; then
- soname=`eval echo \"$soname_spec\"`
+ soname=`eval $echo \"$soname_spec\"`
else
soname="$realname"
fi
done
# Use standard objects if they are PIC.
- test -z "$pic_flag" && libobjs=`echo "$libobjs " | sed -e 's/\.lo /.o /g' -e 's/ $//g'`
+ test -z "$pic_flag" && libobjs=`$echo "$libobjs " | sed -e 's/\.lo /.o /g' -e 's/ $//g'`
# Do each of the archive commands.
- cmds=`eval echo \"$archive_cmds\"`
- IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
+ cmds=`eval $echo \"$archive_cmds\"`
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
for cmd in $cmds; do
IFS="$save_ifs"
$show "$cmd"
*.lo | *.o)
if test -n "$link_against_libtool_libs"; then
- echo "$progname: error: cannot link libtool libraries into reloadable objects" 1>&2
+ $echo "$progname: error: cannot link libtool libraries into reloadable objects" 1>&2
exit 1
fi
if test -n "$deplibs"; then
- echo "$progname: warning: \`-l' and \`-L' are ignored while creating objects" 1>&2
+ $echo "$progname: warning: \`-l' and \`-L' are ignored while creating objects" 1>&2
fi
if test -n "$dlfiles$dlprefiles"; then
- echo "$progname: warning: \`-dlopen' is ignored while creating objects" 1>&2
+ $echo "$progname: warning: \`-dlopen' is ignored while creating objects" 1>&2
# Nullify the symbol file.
- compile_command=`echo "$compile_command" | sed "s% @SYMFILE@%%"`
- finalize_command=`echo "$finalize_command" | sed "s% @SYMFILE@%%"`
+ compile_command=`$echo "$compile_command" | sed "s% @SYMFILE@%%"`
+ finalize_command=`$echo "$finalize_command" | sed "s% @SYMFILE@%%"`
fi
if test -n "$install_libdir"; then
- echo "$progname: warning: \`-rpath' is ignored while creating objects" 1>&2
+ $echo "$progname: warning: \`-rpath' is ignored while creating objects" 1>&2
fi
if test -n "$vinfo"; then
- echo "$progname: warning: \`-version-info' is ignored while creating objects" 1>&2
+ $echo "$progname: warning: \`-version-info' is ignored while creating objects" 1>&2
fi
case "$output" in
*.lo)
if test -n "$objs"; then
- echo "$progname: cannot build library object \`$output' from non-libtool objects" 1>&2
+ $echo "$progname: cannot build library object \`$output' from non-libtool objects" 1>&2
exit 1
fi
libobj="$output"
- obj=`echo "$output" | sed 's/\.lo$/.o/'`
+ obj=`$echo "$output" | sed 's/\.lo$/.o/'`
;;
*)
libobj=
$run $rm $obj $libobj
# Create the old-style object.
- reload_objs="$objs"`echo "$libobjs " | sed -e 's/[^ ]*\.a //g' -e 's/\.lo /.o /g' -e 's/ $//g'`
+ reload_objs="$objs"`$echo "$libobjs " | sed -e 's/[^ ]*\.a //g' -e 's/\.lo /.o /g' -e 's/ $//g'`
output="$obj"
- cmds=`eval echo \"$reload_cmds\"`
- IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
+ cmds=`eval $echo \"$reload_cmds\"`
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
for cmd in $cmds; do
IFS="$save_ifs"
$show "$cmd"
if test "$build_libtool_libs" != yes; then
# Create an invalid libtool object if no PIC, so that we don't
# accidentally link it into a program.
- $show "echo timestamp > $libobj"
- $run eval "echo timestamp > $libobj" || exit $?
+ $show "$echo timestamp > $libobj"
+ $run eval "$echo timestamp > $libobj" || exit $?
exit 0
fi
# Only do commands if we really have different PIC objects.
reload_objs="$libobjs"
output="$libobj"
- cmds=`eval echo \"$reload_cmds\"`
- IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
+ cmds=`eval $echo \"$reload_cmds\"`
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
for cmd in $cmds; do
IFS="$save_ifs"
$show "$cmd"
*)
if test -n "$install_libdir"; then
- echo "$progname: warning: \`-rpath' is ignored while linking programs" 1>&2
+ $echo "$progname: warning: \`-rpath' is ignored while linking programs" 1>&2
fi
if test -n "$vinfo"; then
- echo "$progname: warning: \`-version-info' is ignored while linking programs" 1>&2
+ $echo "$progname: warning: \`-version-info' is ignored while linking programs" 1>&2
fi
if test -n "$libobjs"; then
# Transform all the library objects into standard objects.
- compile_command=`echo "$compile_command " | sed -e 's/\.lo /.o /g' -e 's/ $//'`
- finalize_command=`echo "$finalize_command " | sed -e 's/\.lo /.o /g' -e 's/ $//'`
+ compile_command=`$echo "$compile_command " | sed -e 's/\.lo /.o /g' -e 's/ $//'`
+ finalize_command=`$echo "$finalize_command " | sed -e 's/\.lo /.o /g' -e 's/ $//'`
fi
if test "$export_dynamic" = yes && test -n "$global_symbol_pipe" && test -n "$NM"; then
# Add our own program objects to the preloaded list.
- dlprefiles=`echo "$objs$dlprefiles " | sed -e 's/\.lo /.o /g' -e 's/ $//'`
+ dlprefiles=`$echo "$objs$dlprefiles " | sed -e 's/\.lo /.o /g' -e 's/ $//'`
# Discover the nlist of each of the dlfiles.
dlsyms="$objdir/${output}S.c"
$run rm -f "$nlist" "$nlist"T
for arg in $dlprefiles; do
- echo "extracting global symbols from \`$arg'"
+ $echo "extracting global symbols from \`$arg'"
$run eval "$NM $arg | $global_symbol_pipe >> '$nlist'"
done
# Parse the name list into a C file.
- echo "creating $dlsyms"
+ $echo "creating $dlsyms"
if test -z "$run"; then
# Try sorting and uniquifying the output.
if sort "$nlist" | uniq > "$nlist"T; then
mv -f "$nlist"T "$nlist"
wcout=`wc "$nlist" 2>/dev/null`
- count=`echo "$wcout" | sed 's/^[ ]*\([0-9][0-9]*\).*$/\1/'`
+ count=`$echo "$wcout" | sed 's/^[ ]*\([0-9][0-9]*\).*$/\1/'`
test "$wcout" = "$count" && count=-1
else
rm -f "$nlist"T
/* $dlsyms - symbol resolution table for \`$output' dlsym emulation. */
/* Generated by $PROGRAM - GNU $PACKAGE $VERSION */
+/* Prevent the only kind of circular reference mistakes we can make. */
+#define dld_preloaded_symbol_count some_other_symbol
+#define dld_preloaded_symbols some_other_symbol
+
/* External symbol declarations for the compiler. */
EOF
if test -f "$nlist"; then
- # Prevent the only kind of circular reference mistakes we can make.
- sed -e '/ dld_preloaded_symbol\(s\|_count\)$/d' -e 's/^.* \(.*\)$/extern char \1;/' < "$nlist" >> "$dlsyms"
+ sed -e 's/^.* \(.*\)$/extern char \1;/' < "$nlist" >> "$dlsyms"
else
- echo "/* NONE */" >> "$dlsyms"
+ $echo "/* NONE */" >> "$dlsyms"
fi
cat <<EOF >> "$dlsyms"
+#undef dld_preloaded_symbol_count
+#undef dld_preloaded_symbols
+
#if defined (__STDC__) && __STDC__
# define __ptr_t void *
#else
$run eval '(cd $objdir && $CC -c$no_builtin_flag "${output}S.c")' || exit $?
# Transform the symbol file into the correct name.
- compile_command=`echo "$compile_command" | sed "s%@SYMFILE@%$objdir/${output}S.o%"`
- finalize_command=`echo "$finalize_command" | sed "s%@SYMFILE@%$objdir/${output}S.o%"`
+ compile_command=`$echo "$compile_command" | sed "s%@SYMFILE@%$objdir/${output}S.o%"`
+ finalize_command=`$echo "$finalize_command" | sed "s%@SYMFILE@%$objdir/${output}S.o%"`
elif test "$export_dynamic" != yes; then
- test -n "$dlfiles$dlprefiles" && echo "$progname: warning: \`-dlopen' and \`-dlpreopen' are ignored without \`-export-dynamic'" 1>&2
+ test -n "$dlfiles$dlprefiles" && $echo "$progname: warning: \`-dlopen' and \`-dlpreopen' are ignored without \`-export-dynamic'" 1>&2
else
# We keep going just in case the user didn't refer to
# dld_preloaded_symbols. The linker will fail if global_symbol_pipe
# really was required.
- echo "$progname: not configured to extract global symbols from dlpreopened files" 1>&2
+ $echo "$progname: not configured to extract global symbols from dlpreopened files" 1>&2
# Nullify the symbol file.
- compile_command=`echo "$compile_command" | sed "s% @SYMFILE@%%"`
- finalize_command=`echo "$finalize_command" | sed "s% @SYMFILE@%%"`
+ compile_command=`$echo "$compile_command" | sed "s% @SYMFILE@%%"`
+ finalize_command=`$echo "$finalize_command" | sed "s% @SYMFILE@%%"`
fi
if test -z "$link_against_libtool_libs" || test "$build_libtool_libs" != yes; then
# Replace the output file specification.
- compile_command=`echo "$compile_command" | sed 's%@OUTPUT@%'"$output"'%g'`
- finalize_command=`echo "$finalize_command" | sed 's%@OUTPUT@%'"$output"'%g'`
+ compile_command=`$echo "$compile_command" | sed 's%@OUTPUT@%'"$output"'%g'`
+ finalize_command=`$echo "$finalize_command" | sed 's%@OUTPUT@%'"$output"'%g'`
# We have no uninstalled library dependencies, so finalize right now.
$show "$compile_command"
# If we failed to link statically, then try again.
if test $status -ne 0 && test -n "$link_static"; then
- echo "$progname: cannot link \`$output' statically; retrying semi-dynamically" 1>&2
- compile_command=`echo "$compile_command " | sed -e "s% $link_static % %" -e 's/ $//'`
+ $echo "$progname: cannot link \`$output' statically; retrying semi-dynamically" 1>&2
+ compile_command=`$echo "$compile_command " | sed -e "s% $link_static % %" -e 's/ $//'`
$show "$compile_command"
$run eval "$compile_command"
status=$?
fi
# Replace the output file specification.
- compile_command=`echo "$compile_command" | sed 's%@OUTPUT@%'"$objdir/$output"'%g'`
- finalize_command=`echo "$finalize_command" | sed 's%@OUTPUT@%'"$objdir/$output"'T%g'`
+ compile_command=`$echo "$compile_command" | sed 's%@OUTPUT@%'"$objdir/$output"'%g'`
+ finalize_command=`$echo "$finalize_command" | sed 's%@OUTPUT@%'"$objdir/$output"'T%g'`
# Create the binary in the object directory, then wrap it.
if test -d $objdir; then :
case "$hardcode_action" in
relink)
# AGH! Flame the AIX and HP-UX people for me, will ya?
- echo "$progname: warning: using a buggy system linker" 1>&2
- echo "$progname: relinking will be required before \`$output' can be installed" 1>&2
+ $echo "$progname: warning: using a buggy system linker" 1>&2
+ $echo "$progname: relinking will be required before \`$output' can be installed" 1>&2
;;
esac
$run eval "$compile_command" || exit $?
# Now create the wrapper script.
- echo "creating $output"
+ $echo "creating $output"
# Quote the finalize command for shipping.
- finalize_command=`echo "$finalize_command" | sed "$sed_quote_subst"`
+ finalize_command=`$echo "$finalize_command" | sed "$sed_quote_subst"`
# Only actually do things if our run command is non-null.
if test -z "$run"; then
test "\$libtool_execute_magic" = "$magic" || file="\$0"
# Find the directory that this script lives in.
- thisdir=\`echo "\$file" | sed 's%/[^/]*$%%'\`
+ thisdir=\`$echo "\$file" | sed 's%/[^/]*$%%'\`
test "x\$thisdir" = "x\$file" && thisdir=.
# Try to get the absolute directory name.
$shlibpath_var="$temp_rpath\$$shlibpath_var"
# Some systems cannot cope with colon-terminated $shlibpath_var
- $shlibpath_var=\`echo \$$shlibpath_var | sed -e 's/:*\$//'\`
+ $shlibpath_var=\`$echo \$$shlibpath_var | sed -e 's/:*\$//'\`
export $shlibpath_var
do
# Quote arguments (to preserve shell metacharacters).
sed_quote_subst='$sed_quote_subst'
- arg=\`echo "\$arg" | sed "\$sed_quote_subst"\`
+ arg=\`$echo "\$arg" | sed "\$sed_quote_subst"\`
args="\$args \\"\$arg\\""
done
eval "exec \$program \$args"
- echo "\$0: cannot exec \$program \$args"
+ $echo "\$0: cannot exec \$program \$args"
exit 1
fi
else
# The program doesn't exist.
- echo "\$0: error: neither \$oprogdir/\$program nor \$progdir/\$program exists" 1>&2
- echo "This script is just a wrapper for \$program." 1>&2
- echo "See the $PACKAGE documentation for more information." 1>&2
+ $echo "\$0: error: neither \$oprogdir/\$program nor \$progdir/\$program exists" 1>&2
+ $echo "This script is just a wrapper for \$program." 1>&2
+ $echo "See the $PACKAGE documentation for more information." 1>&2
exit 1
fi
fi
oldlib="$objdir/$libname.a"
# Transform .lo files to .o files.
- oldobjs="$objs"`echo "$libobjs " | sed -e 's/[^ ]*\.a //g' -e 's/\.lo /.o /g' -e 's/ $//g'`
+ oldobjs="$objs"`$echo "$libobjs " | sed -e 's/[^ ]*\.a //g' -e 's/\.lo /.o /g' -e 's/ $//g'`
if test -d "$objdir"; then
$show "$rm $oldlib"
fi
# Do each command in the archive commands.
- cmds=`eval echo \"$old_archive_cmds\"`
- IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
+ cmds=`eval $echo \"$old_archive_cmds\"`
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
for cmd in $cmds; do
IFS="$save_ifs"
$show "$cmd"
old_library=
test "$build_old_libs" = yes && old_library="$libname.a"
- echo "creating $output"
+ $echo "creating $output"
# Only create the output if not a dry run.
if test -z "$run"; then
# The first argument is the name of the installation program.
# Aesthetically quote it.
- arg=`echo "$nonopt" | sed "$sed_quote_subst"`
+ arg=`$echo "$nonopt" | sed "$sed_quote_subst"`
case "$arg" in
*[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*)
arg="\"$arg\""
esac
# Aesthetically quote the argument.
- arg=`echo "$arg" | sed "$sed_quote_subst"`
+ arg=`$echo "$arg" | sed "$sed_quote_subst"`
case "$arg" in
*[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*)
arg="\"$arg\""
done
if test -z "$install_prog"; then
- echo "$progname: you must specify an install program" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: you must specify an install program" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
if test -n "$prev"; then
- echo "$progname: the \`$prev' option requires an argument" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: the \`$prev' option requires an argument" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
if test -z "$files"; then
if test -z "$dest"; then
- echo "$progname: no file or destination specified" 1>&2
+ $echo "$progname: no file or destination specified" 1>&2
else
- echo "$progname: you must specify a destination" 1>&2
+ $echo "$progname: you must specify a destination" 1>&2
fi
- echo "$help" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
# Strip any trailing slash from the destination.
- dest=`echo "$dest" | sed 's%/$%%'`
+ dest=`$echo "$dest" | sed 's%/$%%'`
# Check to see that the destination is a directory.
test -d "$dest" && isdir=yes
destdir="$dest"
destname=
else
- destdir=`echo "$dest" | sed 's%/[^/]*$%%'`
+ destdir=`$echo "$dest" | sed 's%/[^/]*$%%'`
test "X$destdir" = "X$dest" && destdir=.
- destname=`echo "$dest" | sed 's%^.*/%%'`
+ destname=`$echo "$dest" | sed 's%^.*/%%'`
# Not a directory, so check to see that there is only one file specified.
set dummy $files
if test $# -gt 2; then
- echo "$progname: \`$dest' is not a directory" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: \`$dest' is not a directory" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
fi
case "$file" in
*.lo) ;;
*)
- echo "$progname: \`$destdir' must be an absolute directory name" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: \`$destdir' must be an absolute directory name" 1>&2
+ $echo "$help" 1>&2
exit 1
;;
esac
# Check to see that this really is a libtool archive.
if egrep "^# Generated by ltmain.sh" $file >/dev/null 2>&1; then :
else
- echo "$progname: \`$file' is not a valid libtool archive" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: \`$file' is not a valid libtool archive" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
esac
fi
- dir="`echo "$file" | sed 's%/[^/]*$%%'`/"
+ dir="`$echo "$file" | sed 's%/[^/]*$%%'`/"
test "X$dir" = "X$file/" && dir=
dir="$dir$objdir"
$show "$striplib $destdir/$realname"
$run $striplib $destdir/$realname || exit $?
else
- echo "$progname: warning: no library stripping program" 1>&2
+ $echo "$progname: warning: no library stripping program" 1>&2
fi
fi
# Do each command in the postinstall commands.
lib="$destdir/$realname"
- cmds=`eval echo \"$postinstall_cmds\"`
- IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
+ cmds=`eval $echo \"$postinstall_cmds\"`
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
for cmd in $cmds; do
IFS="$save_ifs"
$show "$cmd"
fi
# Install the pseudo-library for information purposes.
- name=`echo "$file" | sed 's%^.*/%%'`
+ name=`$echo "$file" | sed 's%^.*/%%'`
$show "$install_prog $file $destdir/$name"
$run eval "$install_prog $file $destdir/$name" || exit $?
if test -n "$destname"; then
destfile="$destdir/$destname"
else
- destfile=`echo "$file" | sed 's%^.*/%%'`
+ destfile=`$echo "$file" | sed 's%^.*/%%'`
destfile="$destdir/$destfile"
fi
# Deduce the name of the destination old-style object file.
case "$destfile" in
*.lo)
- staticdest=`echo "$destfile" | sed 's/\.lo$/\.o/'`
+ staticdest=`$echo "$destfile" | sed 's/\.lo$/\.o/'`
;;
*.o)
staticdest="$destfile"
destfile=
;;
*)
- echo "$progname: cannot copy a libtool object to \`$destfile'" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: cannot copy a libtool object to \`$destfile'" 1>&2
+ $echo "$help" 1>&2
exit 1
;;
esac
# Install the old object if enabled.
if test "$build_old_libs" = yes; then
# Deduce the name of the old-style object file.
- staticobj=`echo "$file" | sed 's/\.lo$/\.o/'`
+ staticobj=`$echo "$file" | sed 's/\.lo$/\.o/'`
$show "$install_prog $staticobj $staticdest"
$run eval "$install_prog \$staticobj \$staticdest" || exit $?
# Check the variables that should have been set.
if test -z "$link_against_libtool_libs" || test -z "$finalize_command"; then
- echo "$progname: invalid libtool wrapper script \`$file'" 1>&2
+ $echo "$progname: invalid libtool wrapper script \`$file'" 1>&2
exit 1
fi
*) . ./$lib ;;
esac
fi
- libfile="$libdir/`echo "$lib" | sed 's%^.*/%%g'`"
+ libfile="$libdir/`$echo "$lib" | sed 's%^.*/%%g'`"
if test -z "$libdir"; then
- echo "$progname: warning: \`$lib' contains no -rpath information" 1>&2
+ $echo "$progname: warning: \`$lib' contains no -rpath information" 1>&2
elif test -f "$libfile"; then :
else
- echo "$progname: warning: \`$lib' has not been installed in \`$libdir'" 1>&2
+ $echo "$progname: warning: \`$lib' has not been installed in \`$libdir'" 1>&2
finalize=no
fi
done
if test "$hardcode_action" = relink; then
if test "$finalize" = yes; then
- echo "$progname: warning: relinking \`$file' on behalf of your buggy system linker" 1>&2
+ $echo "$progname: warning: relinking \`$file' on behalf of your buggy system linker" 1>&2
$show "$finalize_command"
if $run eval "$finalize_command"; then :
else
- echo "$progname: error: relink \`$file' with the above command before installing it" 1>&2
+ $echo "$progname: error: relink \`$file' with the above command before installing it" 1>&2
continue
fi
file="$objdir/$file"T
else
- echo "$progname: warning: cannot relink \`$file' on behalf of your buggy system linker" 1>&2
+ $echo "$progname: warning: cannot relink \`$file' on behalf of your buggy system linker" 1>&2
fi
else
# Install the binary that we compiled earlier.
- file=`echo "$file" | sed "s%\([^/]*\)$%$objdir/\1%"`
+ file=`$echo "$file" | sed "s%\([^/]*\)$%$objdir/\1%"`
fi
fi
done
for file in $staticlibs; do
- name=`echo "$file" | sed 's%^.*/%%'`
+ name=`$echo "$file" | sed 's%^.*/%%'`
# Set up the ranlib parameters.
oldlib="$destdir/$name"
$show "$old_striplib $oldlib"
$run $old_striplib $oldlib || exit $?
else
- echo "$progname: warning: no static library stripping program" 1>&2
+ $echo "$progname: warning: no static library stripping program" 1>&2
fi
fi
# Do each command in the postinstall commands.
- cmds=`eval echo \"$old_postinstall_cmds\"`
- IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
+ cmds=`eval $echo \"$old_postinstall_cmds\"`
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
for cmd in $cmds; do
IFS="$save_ifs"
$show "$cmd"
done
if test -n "$future_libdirs"; then
- echo "$progname: warning: remember to run \`$progname --finish$future_libdirs'" 1>&2
+ $echo "$progname: warning: remember to run \`$progname --finish$future_libdirs'" 1>&2
fi
if test -n "$current_libdirs"; then
for libdir in $libdirs; do
# Do each command in the postinstall commands.
- cmds=`eval echo \"$finish_cmds\"`
- IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
+ cmds=`eval $echo \"$finish_cmds\"`
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS=';'
for cmd in $cmds; do
IFS="$save_ifs"
$show "$cmd"
done
fi
- echo "To link against installed libraries in LIBDIR, users may have to:"
+ $echo "To link against installed libraries in LIBDIR, users may have to:"
if test -n "$shlibpath_var"; then
- echo " - add LIBDIR to their \`$shlibpath_var' environment variable"
+ $echo " - add LIBDIR to their \`$shlibpath_var' environment variable"
fi
- echo " - use the \`-LLIBDIR' linker flag"
+ $echo " - use the \`-LLIBDIR' linker flag"
exit 0
;;
# The first argument is the command name.
cmd="$nonopt"
if test -z "$cmd"; then
- echo "$progname: you must specify a COMMAND" 1>&2
- echo "$help"
+ $echo "$progname: you must specify a COMMAND" 1>&2
+ $echo "$help"
exit 1
fi
for file in $execute_dlfiles; do
if test -f "$file"; then :
else
- echo "$progname: \`$file' is not a file" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: \`$file' is not a file" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
# Check to see that this really is a libtool archive.
if egrep "^# Generated by ltmain.sh" $file >/dev/null 2>&1; then :
else
- echo "$progname: \`$lib' is not a valid libtool archive" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: \`$lib' is not a valid libtool archive" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
# Skip this library if it cannot be dlopened.
if test -z "$dlname"; then
# Warn if it was a shared library.
- test -n "$library_names" && echo "$progname: warning: \`$file' was not linked with \`-export-dynamic'"
+ test -n "$library_names" && $echo "$progname: warning: \`$file' was not linked with \`-export-dynamic'"
continue
fi
- dir=`echo "$file" | sed 's%/[^/]*$%%'`
+ dir=`$echo "$file" | sed 's%/[^/]*$%%'`
test "X$dir" = "X$file" && dir=.
if test -f "$dir/$objdir/$dlname"; then
dir="$dir/$objdir"
else
- echo "$progname: cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" 1>&2
+ $echo "$progname: cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" 1>&2
exit 1
fi
;;
*.lo)
# Just add the directory containing the .lo file.
- dir=`echo "$file" | sed 's%/[^/]*$%%'`
+ dir=`$echo "$file" | sed 's%/[^/]*$%%'`
test "X$dir" = "X$file" && dir=.
;;
*)
- echo "$progname: warning \`-dlopen' is ignored for non-libtool libraries and objects" 1>&2
+ $echo "$progname: warning \`-dlopen' is ignored for non-libtool libraries and objects" 1>&2
continue
;;
esac
;;
esac
# Quote arguments (to preserve shell metacharacters).
- file=`echo "$file" | sed "$sed_quote_subst"`
+ file=`$echo "$file" | sed "$sed_quote_subst"`
args="$args \"$file\""
done
# Now actually exec the command.
eval "exec \$cmd$args"
- echo "$progname: cannot exec \$cmd$args"
+ $echo "$progname: cannot exec \$cmd$args"
exit 1
else
# Display what would be done.
- eval "echo \"\$shlibpath_var=\$$shlibpath_var\""
- echo "export $shlibpath_var"
- echo "$cmd$args"
+ eval "$echo \"\$shlibpath_var=\$$shlibpath_var\""
+ $echo "export $shlibpath_var"
+ $echo "$cmd$args"
exit 0
fi
;;
done
if test -z "$rm"; then
- echo "$progname: you must specify an RM program" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: you must specify an RM program" 1>&2
+ $echo "$help" 1>&2
exit 1
fi
for file in $files; do
- dir=`echo "$file" | sed -e 's%/[^/]*$%%'`
+ dir=`$echo "$file" | sed -e 's%/[^/]*$%%'`
test "X$dir" = "X$file" && dir=.
- name=`echo "$file" | sed -e 's%^.*/%%'`
+ name=`$echo "$file" | sed -e 's%^.*/%%'`
rmfiles="$file"
*.lo)
if test "$build_old_libs" = yes; then
- oldobj=`echo "$name" | sed 's/\.lo$/\.o/'`
+ oldobj=`$echo "$name" | sed 's/\.lo$/\.o/'`
rmfiles="$rmfiles $dir/$oldobj"
fi
;;
;;
"")
- echo "$progname: you must specify a MODE" 1>&2
- echo "$generic_help" 1>&2
+ $echo "$progname: you must specify a MODE" 1>&2
+ $echo "$generic_help" 1>&2
exit 1
;;
esac
- echo "$progname: invalid operation mode \`$mode'" 1>&2
- echo "$generic_help" 1>&2
+ $echo "$progname: invalid operation mode \`$mode'" 1>&2
+ $echo "$generic_help" 1>&2
exit 1
fi # test -z "$show_help"
;;
*)
- echo "$progname: invalid operation mode \`$mode'" 1>&2
- echo "$help" 1>&2
+ $echo "$progname: invalid operation mode \`$mode'" 1>&2
+ $echo "$help" 1>&2
exit 1
;;
esac
-case "$mode" in
-archive|compile)
- echo
- echo "Try \`$progname --help' for more information about other modes."
- ;;
-esac
+$echo
+$echo "Try \`$progname --help' for more information about other modes."
exit 0