|
From: | John Haxby |
Subject: | Re: [Qemu-devel] configure echo usage |
Date: | Wed, 17 Dec 2008 09:32:17 +0000 |
User-agent: | Thunderbird 2.0.0.18 (X11/20081119) |
Lev Lvovsky wrote:
bash-3.2$ svn diff configure Index: configure =================================================================== --- configure (revision 6069) +++ configure (working copy) @@ -1094,8 +1094,7 @@ test -f $config_h && mv $config_h ${config_h}~echo "# Automatically generated by configure - do not modify" > $config_mak-echo -n "# Configured with:" >> $config_mak -printf " '%s'" "$0" "$@" >> $config_mak +printf "# Configured with: $0 $@" >> $config_mak echo >> $config_makecho "/* Automatically generated by configure - do not modify */" > $config_h
That doesn't give the same output: the original puts each of $0 and the $@'s with single quotes around them in the config file, yours misses out the quotes. Replacing the original echo -n, printf and echo like this would work though:
echo "# Configured with:$(printf " '%s'" "$0" "$@")" >> $config_makIf the OS X shell doesn't do $(...) then this will work, albeit at the cost of readabilty
echo "# Configured with:"`printf " '%s'" "$0" "$@"` >> $config_mak(those pesky backquotes are harder to see and for the ultra-picky it's not quite the same thing).
jch
[Prev in Thread] | Current Thread | [Next in Thread] |