From edd01b7729d84c8c7d00e118b4eee55d46da8030 Mon Sep 17 00:00:00 2001 From: "Yann E. MORIN\"" Date: Fri, 15 Nov 2013 21:21:12 +0100 Subject: libc/(e)glibc: fix extra configparms In case ${CT_LIBC_GLIBC_CONFIGPARMS} starts with a dash, printf will try to interpret it as an option for itself, and will invariably flail in panic as it does not recognise any of it. Use a more robust solution, as suggested by Cody. Reported-by: "Roberto A. Foglietta" Signed-off-by: "Yann E. MORIN" Cc: Cody P Schafer diff --git a/scripts/build/libc/glibc-eglibc.sh-common b/scripts/build/libc/glibc-eglibc.sh-common index c01e671..b9c55cb 100644 --- a/scripts/build/libc/glibc-eglibc.sh-common +++ b/scripts/build/libc/glibc-eglibc.sh-common @@ -304,7 +304,7 @@ do_libc_backend_once() { fi # Pre-seed the configparms file with values from the config option - printf "${CT_LIBC_GLIBC_CONFIGPARMS}\n" > configparms + printf "%s\n" "${CT_LIBC_GLIBC_CONFIGPARMS}" > configparms cross_cc=$(CT_Which "${CT_TARGET}-gcc") extra_cc_args+=" ${extra_flags}" -- cgit v0.10.2-6-g49f6