|
From: | Maxim Yegorushkin |
Subject: | Re: command line limitation |
Date: | Fri, 14 Jul 2006 08:37:16 +0100 |
User-agent: | Thunderbird 1.5 (Windows/20051201) |
ma wrote:
I have a make file that is automatically generated. It that makefile, I have a variable that is very long. It is around 88K long. When I am trying to pass it to any function (ar for example), the operating system complains that the command line is too long. The other way is to put this variable in a text file and call ar in this way:ar @a.txtThe problem is I don't know how I can write this variable into a file? I can't use something such as echo $(Long_Var) >a.txt since then the command line to echo is too long. Is there any way that I can do in gmake? Is there any function in gmake that help to write a variable into a file?
You could output the variable word by word to a file: words = a b c d foo : @for w in $(words); do echo -n "$$w " >> $@; doneAnd then feed the words from the file to ar as command line arguments using xarg utility.
[Prev in Thread] | Current Thread | [Next in Thread] |