When building gcc-4.8.1, I met a cp command as following:
#!/bin/sh
set -x
fname="cp.sh"
cp -v $fname.{,.bk}
It will occurs error when execute this script:
<29>pli[1050]@~/workspace/shell*0 > sh cp.sh
+ fname=cp.sh
+ cp -v cp.sh{,.bk}
cp: missing destination file operand after âcp.sh{,.bk}â
Try 'cp --help' for more information.
<30>pli[1051]@~/workspace/shell*0 >
But when type it on cmd line directly, it works well as expected. It is very in comprehensive to me.\n
<28>pli[1049]@~/workspace/shell*0 > cp -v cp.sh{,.bk}
cp.sh -> cp.sh.bk
<29>pli[1050]@~/workspace/shell*0 > ^C
bashinstead ofsh. I think I've had this issue before, and doing that solved it.srcfolder. I suggest you read through the LFS especially the sections ongcc.bashoverdash, on Debian you can dodpkg-reconfigure dashand setbashas default shell. Any "performance" benefits usingdashare negligible in my opinion.