configure: add cleanws() function

This function removes leading and trailing spaces and collapses
multiple spaces into one.

Signed-off-by: Mans Rullgard <mans@mansr.com>
(cherry picked from commit bb7a22b584)
This commit is contained in:
Mans Rullgard 2011-02-13 13:06:53 +00:00 committed by Michael Niedermayer
parent 11ab1e409f
commit 8429368d22

4
configure vendored
View File

@ -313,6 +313,10 @@ sh_quote(){
echo "$v"
}
cleanws(){
echo "$@" | sed 's/^ *//;s/ */ /g;s/ *$//'
}
filter(){
pat=$1
shift