List Info

Thread: why can't gnumake utilize non-filename pattern rules?




why can't gnumake utilize non-filename pattern rules?
country flaguser name
United States
2007-03-02 07:51:16
If I have the rule

% : gen%

(without a rule), make won't work - it says "no rule to
build file $*".
If I say 

% : gen%
.PHONY : %

make won't work - it simply skips the pattern rule.

I want to make a dependency chain based on a pattern rule,
without the
pattern rule target necessarily being a file. Why can't I do
this? Or
how could I do this?
-- 
%  Randy Yates                  % "I met someone who
looks alot like you,
%% Fuquay-Varina, NC            %             she does the
things you do, 
%%% 919-577-9882                %                     but
she is an IBM."
%%%% <yatesieee.org>           %        'Yours
Truly, 2095', *Time*, ELO   
http://home.earthl
ink.net/~yatescr
_______________________________________________
help-gnu-utils mailing list
help-gnu-utilsgnu.org

http://lists.gnu.org/mailman/listinfo/help-gnu-utils

Re: why can't gnumake utilize non-filename pattern rules?
country flaguser name
Sweden
2007-03-02 14:18:54
Randy Yates <yatesieee.org> wrote:
> make won't work - it simply skips the pattern rule.

I have a vauge memory about a bug in gnu make 3.80. If I
remember right
the bug caused make to skip pattern rules at some
circumstances. For
me it helped to upgrade to version 3.81 of gnu make to avoid
the problem.

Are you using a version of gnu make older than 3.81?

regards Henrik
-- 
The address in the header is only to prevent spam. My real
address is:
hc1(at)poolhem.se Examples of addresses which go to
spammers:
rootlocalhost postmasterlocalhost

_______________________________________________
help-gnu-utils mailing list
help-gnu-utilsgnu.org

http://lists.gnu.org/mailman/listinfo/help-gnu-utils

Re: why can't gnumake utilize non-filename pattern rules?
country flaguser name
United States
2007-03-02 20:51:57
Henrik Carlqvist <Henrik.Carlqvistdeadspam.com> writes:

> Randy Yates <yatesieee.org> wrote:
>> make won't work - it simply skips the pattern
rule.
>
> I have a vauge memory about a bug in gnu make 3.80. If
I remember right
> the bug caused make to skip pattern rules at some
circumstances. For
> me it helped to upgrade to version 3.81 of gnu make to
avoid the problem.
>
> Are you using a version of gnu make older than 3.81?

Hi Henrik,

Thank you for responding. 

No, I am using 3.81. 

This is not a bug - it's in the manual. 

  Since it knows that phony targets do not name actual files
that could
  be remade from other files, make skips the implicit rule
search for
  phony targets (see Chapter 10 [Implicit Rules], page 89).
This is
  why declaring a target phony is good for performance, even
if you
  are not worried about the actual file existing.


-- 
%  Randy Yates                  % "Midnight, on the
water... 
%% Fuquay-Varina, NC            %  I saw...  the ocean's
daughter." 
%%% 919-577-9882                % 'Can't Get It Out Of My
Head' 
%%%% <yatesieee.org>           % *El Dorado*,
Electric Light Orchestra
http://home.earthl
ink.net/~yatescr
_______________________________________________
help-gnu-utils mailing list
help-gnu-utilsgnu.org

http://lists.gnu.org/mailman/listinfo/help-gnu-utils

[1-3]

about | contact  Other archives ( Real Estate discussion Medical topics )