From: Gary V. Vaughan Date: Mon, 10 Sep 2001 23:33:26 +0000 (+0000) Subject: * libtool.m4: CVS Autoconf guarantees a decent default IFS, so X-Git-Tag: release-1-4d~39 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4a57948985638d7cabbb40c3aa4a2d2e83f3e2e9;p=thirdparty%2Flibtool.git * libtool.m4: CVS Autoconf guarantees a decent default IFS, so there is no need for us to preset it anymore. Be careful not to set IFS="${IFS}$PATH_SEPARATOR" for PATH splitting, otherwise spaces in directory names will be lost. Use $PATH_SEPARATOR... don't rely on $ac_path_separator, which was an autoconf internal until just now, when it disappeared! * ltmain.in: Default IFS once, at the start. Reported by Akim Demaille --- diff --git a/ChangeLog b/ChangeLog index f269947ab..445366227 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2001-09-10 Gary V. Vaughan + + * libtool.m4: CVS Autoconf guarantees a decent default IFS, so + there is no need for us to preset it anymore. + Be careful not to set IFS="${IFS}$PATH_SEPARATOR" for PATH + splitting, otherwise spaces in directory names will be lost. + Use $PATH_SEPARATOR... don't rely on $ac_path_separator, which was + an autoconf internal until just now, when it disappeared! + * ltmain.in: Default IFS once, at the start. + Reported by Akim Demaille + 2001-09-10 Brad * libtool.m4 (AC_DEPLIBS_CHECK_METHOD): Missed an instance of diff --git a/libtool.m4 b/libtool.m4 index 16aa38c7c..e68ea04cc 100644 --- a/libtool.m4 +++ b/libtool.m4 @@ -318,7 +318,7 @@ else # # So, first we look for a working echo in the user's PATH. - IFS="${IFS= }"; lt_save_ifs="$IFS"; IFS="${IFS}$ac_path_separator" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for dir in $PATH /usr/ucb; do IFS="$lt_save_ifs" if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && @@ -1087,7 +1087,7 @@ cygwin* | mingw* | pw32*) ;; yes,mingw*) library_names_spec='${libname}`echo ${release} | sed -e 's/[[.]]/-/g'`${versuffix}.dll' - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | sed -e "s/^libraries://" -e "s/$ac_path_separator/ /g"` + sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | sed -e "s/^libraries://" -e "s/$PATH_SEPARATOR/ /g"` ;; yes,pw32*) library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll' @@ -1429,7 +1429,7 @@ if test -f "$ltmain" && test -n "$tagnames"; then # 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'` - IFS="${IFS= }"; lt_save_ifs="$IFS"; IFS="${IFS}$ac_path_separator," + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for tagname in $tagnames; do IFS="$lt_save_ifs" # Check whether tagname contains only valid characters @@ -1512,7 +1512,7 @@ AC_ARG_ENABLE([shared], *) enable_shared=no # Look at the argument we got. We use all the common list separators. - IFS="${IFS= }"; lt_save_ifs="$IFS"; IFS="${IFS}$ac_path_separator," + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then @@ -1551,7 +1551,7 @@ AC_ARG_ENABLE([static], *) enable_static=no # Look at the argument we got. We use all the common list separators. - IFS="${IFS= }"; lt_save_ifs="$IFS"; IFS="${IFS}$ac_path_separator," + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then @@ -1590,7 +1590,7 @@ AC_ARG_ENABLE([fast-install], *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. - IFS="${IFS= }"; lt_save_ifs="$IFS"; IFS="${IFS}$ac_path_separator," + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then @@ -1635,7 +1635,7 @@ AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, ;; *) lt_save_MAGIC_CMD="$MAGIC_CMD" - IFS="${IFS= }"; lt_save_ifs="$IFS"; IFS="$ac_path_separator" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR dnl $ac_dummy forces splitting on constant user-supplied paths. dnl POSIX.2 word splitting is done only on the output of word expansions, dnl not every word. This closes a longstanding sh security hole. @@ -1689,10 +1689,10 @@ fi # ------------- # find a file program which can recognise a shared library AC_DEFUN([AC_PATH_MAGIC], -[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$ac_path_separator$PATH) +[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then - AC_PATH_TOOL_PREFIX(file, /usr/bin$ac_path_separator$PATH) + AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) else MAGIC_CMD=: fi @@ -1750,7 +1750,7 @@ else fi AC_CACHE_VAL(lt_cv_path_LD, [if test -z "$LD"; then - IFS="${IFS= }"; lt_save_ifs="$IFS"; IFS="${IFS}$ac_path_separator" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. @@ -2015,7 +2015,7 @@ AC_DEFUN([AC_PROG_NM], # Let the user override the test. lt_cv_path_NM="$NM" else - IFS="${IFS= }"; lt_save_ifs="$IFS"; IFS="${IFS}$ac_path_separator" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. diff --git a/ltmain.in b/ltmain.in index dd93ee66e..76e680fbf 100644 --- a/ltmain.in +++ b/ltmain.in @@ -84,6 +84,9 @@ if test "${LANG+set}" = set; then save_LANG="$LANG"; LANG=C; export LANG fi +# Make sure IFS has a sensible default +: ${IFS=" "} + if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then echo "$modename: not configured to build any kind of library" 1>&2 echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 @@ -377,7 +380,7 @@ if test -z "$show_help"; then -Wc,*) args=`$echo "X$arg" | $Xsed -e "s/^-Wc,//"` lastarg= - IFS="${IFS= }"; save_ifs="$IFS"; IFS=',' + save_ifs="$IFS"; IFS=',' for arg in $args; do IFS="$save_ifs" @@ -1333,7 +1336,7 @@ EOF -Wc,*) args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wc,//'` arg= - IFS="${IFS= }"; save_ifs="$IFS"; IFS=',' + save_ifs="$IFS"; IFS=',' for flag in $args; do IFS="$save_ifs" case $flag in @@ -1351,7 +1354,7 @@ EOF -Wl,*) args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wl,//'` arg= - IFS="${IFS= }"; save_ifs="$IFS"; IFS=',' + save_ifs="$IFS"; IFS=',' for flag in $args; do IFS="$save_ifs" case $flag in @@ -2131,7 +2134,7 @@ EOF if test -f "$output_objdir/$soname-def"; then : else $show "extracting exported symbol list from \`$soname'" - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' eval cmds=\"$extract_expsyms_cmds\" for cmd in $cmds; do IFS="$save_ifs" @@ -2144,7 +2147,7 @@ EOF # Create $newlib if test -f "$output_objdir/$newlib"; then :; else $show "generating import library for \`$soname'" - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' eval cmds=\"$old_archive_from_expsyms_cmds\" for cmd in $cmds; do IFS="$save_ifs" @@ -2569,7 +2572,7 @@ EOF else # Parse the version information argument. - IFS="${IFS= }"; save_ifs="$IFS"; IFS=':' + save_ifs="$IFS"; IFS=':' set dummy $vinfo 0 0 0 IFS="$save_ifs" @@ -3210,7 +3213,7 @@ EOF export_symbols="$output_objdir/$libname.exp" $run $rm $export_symbols eval cmds=\"$export_symbols_cmds\" - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" $show "$cmd" @@ -3361,7 +3364,7 @@ EOF $echo "creating a temporary reloadable object file: $output" # Loop through the commands generated above and execute them. - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' for cmd in $concat_cmds; do IFS="$save_ifs" $show "$cmd" @@ -3390,7 +3393,7 @@ EOF # to the just-reset $cmds. eval cmds=\"\$cmds~$rm $delfiles\" fi - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" $show "$cmd" @@ -3518,7 +3521,7 @@ EOF output="$obj" eval cmds=\"$reload_cmds\" - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" $show "$cmd" @@ -3554,7 +3557,7 @@ EOF reload_objs="$libobjs $reload_conv_objs" output="$libobj" eval cmds=\"$reload_cmds\" - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" $show "$cmd" @@ -4319,7 +4322,7 @@ fi\ eval cmds=\"\$concat_cmds~$old_archive_cmds\" fi fi - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" $show "$cmd" @@ -4694,7 +4697,7 @@ relink_command=\"$relink_command\"" # Do each command in the postinstall commands. lib="$destdir/$realname" eval cmds=\"$postinstall_cmds\" - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" $show "$cmd" @@ -4881,7 +4884,7 @@ relink_command=\"$relink_command\"" # Do each command in the postinstall commands. eval cmds=\"$old_postinstall_cmds\" - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" $show "$cmd" @@ -4919,7 +4922,7 @@ relink_command=\"$relink_command\"" if test -n "$finish_cmds"; then # Do each command in the finish commands. eval cmds=\"$finish_cmds\" - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" $show "$cmd" @@ -5195,7 +5198,7 @@ relink_command=\"$relink_command\"" if test -n "$library_names"; then # Do each command in the postuninstall commands. eval cmds=\"$postuninstall_cmds\" - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" $show "$cmd" @@ -5210,7 +5213,7 @@ relink_command=\"$relink_command\"" if test -n "$old_library"; then # Do each command in the old_postuninstall commands. eval cmds=\"$old_postuninstall_cmds\" - IFS="${IFS= }"; save_ifs="$IFS"; IFS='~' + save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" $show "$cmd"