From a4d9067709abf0dd27818c41a6d8e2ec09560f71 Mon Sep 17 00:00:00 2001 From: Idwer Vollering Date: Sun, 24 Jul 2016 02:10:19 +0200 Subject: [PATCH] UPSTREAM: buildgcc: Quote command substitution There are shells where the result of a command substitution is subject to word splitting (e.g. dash when assigning a value inside an export statement). BUG=None BRANCH=None TEST=None Signed-off-by: Idwer Vollering Signed-off-by: Nico Huber Reviewed-on: https://review.coreboot.org/15820 Reviewed-by: Paul Menzel Tested-by: build bot (Jenkins) Change-Id: I70a5bc124af7ee621da2bdb4777f3eaba8adafbb Reviewed-on: https://chromium-review.googlesource.com/384960 Commit-Ready: Furquan Shaikh Tested-by: Furquan Shaikh Reviewed-by: Aaron Durbin --- util/crossgcc/buildgcc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/util/crossgcc/buildgcc b/util/crossgcc/buildgcc index d85891976b..9eb72f9dc8 100755 --- a/util/crossgcc/buildgcc +++ b/util/crossgcc/buildgcc @@ -442,8 +442,8 @@ have_hostcflags_from_gmp() { set_hostcflags_from_gmp() { # Now set CFLAGS to match GMP CFLAGS but strip out -pedantic # as GCC 4.6.x fails if it's there. - export HOSTCFLAGS=$(grep __GMP_CFLAGS $DESTDIR$TARGETDIR/include/gmp.h |cut -d\" -f2 |\ - sed s,-pedantic,,) + export HOSTCFLAGS="$(grep __GMP_CFLAGS $DESTDIR$TARGETDIR/include/gmp.h |cut -d\" -f2 |\ + sed s,-pedantic,,)" } build_GMP() {