help-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: echoing a multiline variable (to a flie)


From: Stephan Beal
Subject: Re: echoing a multiline variable (to a flie)
Date: Sat, 1 May 2010 14:27:25 +0200

On Sat, May 1, 2010 at 12:51 PM, Martin Mensch all:
address@hidden -f Test.txt
address@hidden $(LONG_TEXT) >> Test.txt

That can't work in this context because $(LONG_TEXT) is expanded before the recipe. So the recipe ends up looking like:

echo first line
second line
...

How can I do it?

Get rid of the newlines?

Alternately, you could put them in an extra file (possibly generating that file via make) and do:

@cat thefile >> Test.txt

--
----- stephan beal
http://wanderinghorse.net/home/stephan/

reply via email to

[Prev in Thread] Current Thread [Next in Thread]