bug-make
[Top][All Lists]
Advanced

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

Re: Bug#88324: make: pattern rules are broken in some cases


From: Paul D. Smith
Subject: Re: Bug#88324: make: pattern rules are broken in some cases
Date: Thu, 5 Jul 2001 00:46:27 -0400

%% Manoj Srivastava <address@hidden> writes:

  ms>          [Please retain the CC to address@hidden so
  ms>          that the Debian Bug Tracking system can record your input]

  ms> ======================================================================
  ms> Consider the following Makefile:

  ms> %: bar/%.foo
  ms>   @echo success

  ms> Suppose that the following files exist:

  ms>     bar/a.foo
  ms>     bar/b/c.foo

  ms> "make a" prints "success", but "make b/c" says:

  ms>     make: *** No rule to make target `b/c'.  Stop.

  ms> This problem was reported by a Debian user.  I looked through the
  ms> manual to see if there is any restriction on the stem section of a
  ms> pattern match, but I did not see any prohibitions, so this should
  ms> work.

No, this is documented and the behaviour here is correct according to
the documentation.  See the second paragraph in the GNU make manual
section "How Patterns Match".  If the target doesn't contain a slash,
then directory names are removed from the file name before it is
compared.

  ms> I'm almost certain this used to work.

I tried versions of GNU make all the way back to 3.74 with this example,
and they all behaved as above (no rule to make target...).

-- 
-------------------------------------------------------------------------------
 Paul D. Smith <address@hidden>          Find some GNU make tips at:
 http://www.gnu.org                      http://www.paulandlesley.org/gmake/
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist



reply via email to

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