[Top][All Lists]

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

Re: Splitting lines problem in make-3.80 versus 3.81

From: Paul Smith
Subject: Re: Splitting lines problem in make-3.80 versus 3.81
Date: Tue, 8 Sep 2009 16:30:03 -0400

On Tue, 2009-09-08 at 13:02 -0700, Warren Dodge wrote:
> I tried it on my specific problem and indeed it solved the issue. A
> co-worker was working on another Makefile an having a similar issue. We
> tried the solution above and ran into a number if strange issues.

I haven't looked at this yet but I will.

> In 3.81 we had to go to greater lengths to get the operation of the
> Makefile to work. Hee is what the co-worker said about the problem.
>  >>> The variable method can get tricky too, if the perl code you are running
>  >>> makes reference to automatic variables, as they are not defined except
>  >>> in the target.  The perl code in question in this example uses the
>  >>> $(word 2,$^) to get name of the second file in the dependency list, so
>  >>> the variable has to be defined as a Target-Specific or Pattern-Specific
>  >>> variable, but making these in a way that is compatible to both 3.80 and
>  >>> 3.81 is not easy.

This is definitely not true.  All you have to do is use recursive
assignment ("=") and NOT simple assignment (":=").

There is absolutely no difference, other than the line ending
concatenation we are trying to take advantage of, between this:

                echo bar

and this:

        COMMAND = echo bar


_regardless_ of how complex and what content, variable references, etc.
you use to replace "echo bar".

If you use "COMMAND := ...." then definitely you are in for a world of

> Assuming there is a bug we hope it can be addressed. If it is just not
> understanding what is going on maybe the "ifo" page on this subject can
> be enhanced to help others address this.

I believe that the info is correct and factual.  If you try the examples
there and follow the instructions you should be successful.  I'll take a
look at the examples you provided to see if there are holes that need to
be clarified, or if you have specific suggestions about things that are
hard to understand they're very welcome.  As you might guess, when you
already know exactly how it all works it can be difficult to write
documentation that answers all newcomers' questions in an understandable


reply via email to

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