Re: nested backticks in Makefile

2007-03-28 Thread Paolo Bonzini
DJ Delorie wrote: > Ok, I suppose, as long as the backticks still get expanded. They do, ~ bonzinip$ echo "`echo abc`" abc Paolo

Re: nested backticks in Makefile

2007-03-27 Thread DJ Delorie
Ok, I suppose, as long as the backticks still get expanded.

Re: nested backticks in Makefile

2007-03-27 Thread Daniel Jacobowitz
On Tue, Mar 27, 2007 at 10:40:10PM -0400, DJ Delorie wrote: > > > I only meant: > > > > CROSS_SYSTEM_HEADER_DIR='$(shell echo "$(gcc_tooldir)/sys-include")' > > I figured you meant that. Can you think of an example that would > benefit from this quoting? $(gcc_tooldir) starts with $(libsubdir)

Re: nested backticks in Makefile

2007-03-27 Thread DJ Delorie
> I only meant: > > CROSS_SYSTEM_HEADER_DIR='$(shell echo "$(gcc_tooldir)/sys-include")' I figured you meant that. Can you think of an example that would benefit from this quoting?

Re: nested backticks in Makefile

2007-03-27 Thread Daniel Jacobowitz
On Tue, Mar 27, 2007 at 10:28:33PM -0400, DJ Delorie wrote: > > > On Tue, Mar 27, 2007 at 03:01:04PM -0400, DJ Delorie wrote: > > > - CROSS_SYSTEM_HEADER_DIR='$(gcc_tooldir)/sys-include' > > > + CROSS_SYSTEM_HEADER_DIR='$(shell echo $(gcc_tooldir)/sys-include)' > > > > Don't you need more quotes

Re: nested backticks in Makefile

2007-03-27 Thread DJ Delorie
> On Tue, Mar 27, 2007 at 03:01:04PM -0400, DJ Delorie wrote: > > - CROSS_SYSTEM_HEADER_DIR='$(gcc_tooldir)/sys-include' > > + CROSS_SYSTEM_HEADER_DIR='$(shell echo $(gcc_tooldir)/sys-include)' > > Don't you need more quotes than that? I think if we quoted it more, we'd end up passing the backti

Re: nested backticks in Makefile

2007-03-27 Thread Daniel Jacobowitz
On Tue, Mar 27, 2007 at 03:01:04PM -0400, DJ Delorie wrote: > - CROSS_SYSTEM_HEADER_DIR='$(gcc_tooldir)/sys-include' > + CROSS_SYSTEM_HEADER_DIR='$(shell echo $(gcc_tooldir)/sys-include)' Don't you need more quotes than that? -- Daniel Jacobowitz CodeSourcery

Re: nested backticks in Makefile

2007-03-27 Thread DJ Delorie
"Dave Korn" <[EMAIL PROTECTED]> writes: > Doh. Yes, we'd need immediate evaluation *and* $(shell ...). I think it's *or* not *and*. How about this? Seems to work for me. Index: configure.ac === --- configure.ac(revision

Re: nested backticks in Makefile

2007-03-27 Thread Paolo Bonzini
Dave Korn wrote: > On 27 March 2007 18:25, Andreas Schwab wrote: > >> "Dave Korn" <[EMAIL PROTECTED]> writes: >> >>> Or how about using ':=' to force immediate evaluation? >> That won't help, since backquotes are only expanded by the shell, not by >> make. > > Doh. Yes, we'd need immediate e

RE: nested backticks in Makefile

2007-03-27 Thread Dave Korn
On 27 March 2007 18:25, Andreas Schwab wrote: > "Dave Korn" <[EMAIL PROTECTED]> writes: > >> Or how about using ':=' to force immediate evaluation? > > That won't help, since backquotes are only expanded by the shell, not by > make. Doh. Yes, we'd need immediate evaluation *and* $(shell ..

Re: nested backticks in Makefile

2007-03-27 Thread Andreas Schwab
"Dave Korn" <[EMAIL PROTECTED]> writes: > Or how about using ':=' to force immediate evaluation? That won't help, since backquotes are only expanded by the shell, not by make. Andreas. -- Andreas Schwab, SuSE Labs, [EMAIL PROTECTED] SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg,

RE: nested backticks in Makefile

2007-03-27 Thread Dave Korn
On 27 March 2007 17:55, DJ Delorie wrote: > When cross compiling with a sysroot, you sometimes end up with nested > backticks. > > The case we're seeing it with is m32r-elf, where gcc_tooldir is defined > thusly: > > gcc_tooldir = $(libsubdir)/$(unlibsubdir)/`echo $(exec_prefix) | sed -e > 's|

nested backticks in Makefile

2007-03-27 Thread DJ Delorie
When cross compiling with a sysroot, you sometimes end up with nested backticks. The case we're seeing it with is m32r-elf, where gcc_tooldir is defined thusly: gcc_tooldir = $(libsubdir)/$(unlibsubdir)/`echo $(exec_prefix) | sed -e 's|^$(prefix)||' -e 's|/$(dollar)||' -e 's|^[^/]|/|' -e 's|/[