bug-gnu-utils
[Top][All Lists]
Advanced

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

Re: Error in gnu make?


From: j
Subject: Re: Error in gnu make?
Date: 11 Mar 2002 10:47:08 -0800

address@hidden (Hans-Bernhard Broeker) wrote in message news:<address@hidden>...

> I think you're misunderstanding something.  % is substituted only once
> per prerequisite pattern.

        Why did the writers of gnu make choose this convension?  I would
think cases would exist (like the example I gave) where you would want
to substitute more than once....  And since %'s can be escaped (\%)
there is no problem in forcing a % to be part of the filename, so if I
really wanted the second occurance of % to actually be a % it would be
easy to do.

        Is there documentation on this anywhere?  I could not find anything
that referred to multiple occurances of a % in a prerequisite.

> > question 2- Does anyone have a temporary solution for me....  
> 
> I would work around this by calling the *.in files differently.  
> 
>       a/subdir.in
>       b/subdir.in
>       c/subdir.in
> 
> come to mind. In this setup, a rule like
> 
>       $(filenames): %.out : %/subdir.in
> 
> would work.  Or use recursive makes.

        Although I agree with you that this is better, I am bound to the
original way of organizing files....  I am using someone else's
distribution and can not change filename.  I am making a patch to the
Makefile so that it will work better, but the filename convension is
deeply rooted in the scripts used by the distribution.

        I am also surprised that gnu make simply doesn't allow for this
not-so-unusual feature.

                                                        -J



reply via email to

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