On 2/6/06, Jim Gallacher <[EMAIL PROTECTED]> wrote: > A couple of thoughts on this issue. > > According to the gentoo bug report quoted below, the problem in > configure.in is the double backslash escape sequence in the line: > > MP_VERSION=`echo $MP_VERSION | sed s/\\"//g` > > Changing this to: > MP_VERSION=`echo $MP_VERSION | sed s/\"//g` > > > fixes it for bash 3.1. I wonder why we are using \\" since the gentoo > fix seems to work ok with bash 3.0 (and GNU sed) on my system just as > well. Is it there to support other shells, other sed versions, older > bash versions... ?? > > I suggest we either adopt the gentoo fix, or avoid the problem > altogether by using tr. eg. > > MP_VERSION=`echo $MP_VERSION | tr -d '"'` > > I'm assuming tr is always available on UNIX-like systems.
Personally I prefer tr because it's more readable. But I don't know it's availability outside Unix. You can try single-quoting the sed expression and eliminationg the backslashes altogether: MP_VERSION=`echo $MP_VERSION | sed 's/"//g' ` If there is also some problem with a sed treating " as a special character, you can always use character classes: MP_VERSION=`echo $MP_VERSION | sed 's/["]//g' ` I generally find that avoid backslashes at all cost improves portability of scripts across broken shells/seds. -- Deron Meranda