delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/06/24/10:38:00

Message-Id: <200006241437.RAA05163@mailgw1.netvision.net.il>
Date: Sat, 24 Jun 2000 17:38:49 +0200
To: Jason Green <news AT jgreen4 DOT fsnet DOT co DOT uk>
X-Mailer: Emacs 20.6 (via feedmail 8.2.emacs20_6 I) and Blat ver 1.8.5b
From: "Eli Zaretskii" <eliz AT is DOT elta DOT co DOT il>
CC: djgpp AT delorie DOT com
In-reply-to: <qab9lsochni2om19ur20cshpkad7fphpqq@4ax.com> (message from Jason
Green on Sat, 24 Jun 2000 13:48:48 +0100)
Subject: Re: Make file wildcards
References: <395309A1 DOT 881A2311 AT pacbell DOT net> <200006230948 DOT MAA02794 AT mailgw1 DOT netvision DOT net DOT il> <3953D200 DOT 897086E1 AT pacbell DOT net> <mjq7lskslq2g3h46oeobjouvhjuuujantm AT 4ax DOT com> <200006240638 DOT JAA15429 AT alpha DOT netvision DOT net DOT il> <qab9lsochni2om19ur20cshpkad7fphpqq AT 4ax DOT com>
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

> From: Jason Green <news AT jgreen4 DOT fsnet DOT co DOT uk>
> Newsgroups: comp.os.msdos.djgpp
> Date: Sat, 24 Jun 2000 13:48:48 +0100
> > 
> > A Makefile can legitimately have several different implicit rules for
> > the same %.o pattern, and they are all valid.  Make will chose
> > whatever it sees fit out of them.
> 
> Sorry, I still don't get it.  I understand your original reply to mean
> that there are cases where a built-in implicit rule takes precedence
> over an implicit rule defined in the makefile.

With implicit rules, there's no precedence.  You can have several
different implicit rules that can be applied to create the same
target.  Make will choose one of them, but not necessarily the last
one it sees.

> Can you give an example of this (if you really mean that)?

What's wrong with the example which started this thread?

> The original makefile did not contain a rule (implicit or otherwise)
> to compile a .cpp file

The original makefile *did* include a rule to produce foo.o given
foo.cpp.  And that is what important, as far as Make is concerned.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019