Re: [Qemu-devel] [PATCH] config-host.mak: escape configure arguments

2013-10-06 Thread Gabriel Kerneis
On Sun, Oct 06, 2013 at 07:47:02AM +0200, Stefan Weil wrote: What about removing the comment with the configure parameters from config-host.mak? Sound like a good idea. * Easier code - no need to create a configure call from a comment. Note we still need some escaping for single quotes, but

[Qemu-devel] [PATCH] config-host.mak: escape configure arguments

2013-10-05 Thread Gabriel Kerneis
Escape single quotes and newlines when writing configure arguments to config-host.mak. This is necessary to allow correct regeneration by re-executing configure in a shell when config-host.mak becomes out-of-date. Signed-off-by: Gabriel Kerneis gabr...@kerneis.info --- configure | 6 +- 1

Re: [Qemu-devel] [PATCH] config-host.mak: escape configure arguments

2013-10-05 Thread Peter Maydell
On 5 October 2013 23:41, Gabriel Kerneis gabr...@kerneis.info wrote: Escape single quotes and newlines when writing configure arguments to config-host.mak. This is necessary to allow correct regeneration by re-executing configure in a shell when config-host.mak becomes out-of-date.

Re: [Qemu-devel] [PATCH] config-host.mak: escape configure arguments

2013-10-05 Thread Gabriel Kerneis
On Sun, Oct 06, 2013 at 12:54:08AM +0900, Peter Maydell wrote: So this sed script appears to convert literal newlines in the input Is that what's intended? Yes. It doesn't seem very useful because if you cut-n-paste (or pipe) 'hello\nworld' into a shell you get an actual backslash-n, not a

Re: [Qemu-devel] [PATCH] config-host.mak: escape configure arguments

2013-10-05 Thread Stefan Weil
Am 06.10.2013 00:18, schrieb Gabriel Kerneis: On Sun, Oct 06, 2013 at 12:54:08AM +0900, Peter Maydell wrote: So this sed script appears to convert literal newlines in the input Is that what's intended? Yes. It doesn't seem very useful because if you cut-n-paste (or pipe) 'hello\nworld' into