libc/glibc: do not consume parameters when parsing them
author"Yann E. MORIN" <yann.morin.1998@free.fr>
Mon Feb 13 21:47:25 2012 +0100 (2012-02-13)
changeset 2883cea814c9932a
parent 2882 da77b5e7cb9f
child 2884 91017ae2151c
libc/glibc: do not consume parameters when parsing them

Currently, there are two constructs used to parse arguments in
glibc backends, one that consumes args as they are parsed, and
one that does not.

Always use the construct that does not eat args as they are parsed.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
scripts/build/libc/glibc-eglibc.sh-common
     1.1 --- a/scripts/build/libc/glibc-eglibc.sh-common	Mon Feb 13 21:10:06 2012 +0100
     1.2 +++ b/scripts/build/libc/glibc-eglibc.sh-common	Mon Feb 13 21:47:25 2012 +0100
     1.3 @@ -197,10 +197,10 @@
     1.4      local glibc_cflags
     1.5      local float_extra
     1.6      local endian_extra
     1.7 +    local arg
     1.8  
     1.9 -    while [ $# -ne 0 ]; do
    1.10 -        eval "${1// /\\ }"
    1.11 -        shift
    1.12 +    for arg in "$@"; do
    1.13 +        eval "${arg// /\\ }"
    1.14      done
    1.15  
    1.16      CT_DoLog EXTRA "Configuring C library"