buildgcc: Remove all bashisms, making the script run also on BSD
authorPeter Stuge <peter@stuge.se>
Sun, 21 Aug 2011 04:24:55 +0000 (06:24 +0200)
committerPatrick Georgi <patrick@georgi-clan.de>
Sun, 21 Aug 2011 06:47:00 +0000 (08:47 +0200)
commit09377b7d3f62fb62a6e7c11aefdde771a774ea05
tree91dba291e1e641065f5cb9495a12f50280354b64
parent875b9b197f64e845a2c220a1f69a5c1b4000092f
buildgcc: Remove all bashisms, making the script run also on BSD

Use sed instead of ${variable:start:length} and ${#variable}
Use single = in string comparisons
Use `eval echo '$'$variable` instead of ${!variable}
Use > file 2>&1 instead of &> file
Use readlink -f to expand the path of GCC configure

Change-Id: Idc7dfcea3922f55630a6855acdb19e36582708bd
Signed-off-by: Peter Stuge <peter@stuge.se>
Reviewed-on: http://review.coreboot.org/165
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
Tested-by: build bot (Jenkins)
util/crossgcc/buildgcc