I'm trying to compile libiconv. It has this in its configure script:

  sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
func_dirname ()\
{\
\    case ${1} in\
\      */*) func_dirname_result="${1%/*}${2}" ;;\
\      *  ) func_dirname_result="${3}" ;;\
\    esac\
} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \

This results in the following being generated:

func_dirname ()
{
\    case ${1} in
\      */*) func_dirname_result="${1%/*}${2}" ;;
\      *  ) func_dirname_result="${3}" ;;
\    esac
} # Extended-shell func_dirname implementation

i.e. backslashes are left in, which bash barfs on.

The busybox sed stripped out the backslashes, and libiconv compiled fine.
Is Toybox sed only stripping out eol backslashes?

David
_______________________________________________
Toybox mailing list
[email protected]
http://lists.landley.net/listinfo.cgi/toybox-landley.net

Reply via email to