LFS 6.5 - bash fails with command substitution: line 5: syntax error near unexpected token `)'
andreas at kasenides.org
Sat Jan 2 07:33:18 PST 2010
I am using LFS 6.5 on a CentOS 5.4 host.
Everything goes smoothly until I get to
Apparently this is the first script that uses the
newly compiled tools among them /tools/bin/bash
This is where bash begins to fail on command substitutions
of the form $(uname -m) with errors of the form
"command substitution: line 5: syntax error near unexpected token `)'".
Changing from $(uname -m) to `uname -m` corrects this problem.
> From then on it fails on ALL similar commands. Which is very
miserable when you get into 076-util-linux-ng where similar
constructs are used in the configure script with some 20000+ lines!!
In order to test the new bash I created a test file:
which fails with
/tmp/tt: command substitution: line 3: syntax error near unexpected
/tmp/tt: command substitution: line 3: `uname -m)'
This runs nicely with `uname -m`. Same behavior exists with
the .../bin/bash (instead of ../tools/bin/bash).
Instead the same test file run with the host bash:
come back nicely with
Any ideas? AM I doing something wrong?
More information about the lfs-support