From: rri!potter AT vtserf DOT cc DOT vt DOT edu (Mark Allen Potter) Subject: Re: gnu make woes To: ericb AT lsid DOT hp DOT com (Eric Backus) Date: Fri, 15 Apr 1994 18:47:17 -0400 (EDT) Cc: djgpp AT sun DOT soe DOT clarkson DOT edu (DJ G++ Mailing List ) Reply-To: rri!potter AT vtserf DOT cc DOT vt DOT edu > Potter (rri!potter AT vtserf DOT cc DOT vt DOT edu) writes: > > Thanks for the reply. However it did not work. The backslash did > > escape the meaning of the ':', thus no longer conplaining about the missing > > '%'. However the backslash was left in an thus complained about no rule for > > the target. Example: > > > > Makefile: > > > > all: d\:/tmp/source.o > > echo It Worked > > > > Produces: > > > > gmake.exe: *** No rule to make target `d\:/tmp/source.o'. Stop. > > > > I also tried several of the other UNIX style escapings ", ', and `, but none > > worked. Well, thanks for the suggestion. > > I think it might really have worked. The Makefile fragment you show > above does not contain a rule for making "d:/tmp/source.o", so make is > complaining that it doesn't know how to make it. But if you add these > lines: > > d\:/tmp/source.o: > echo commands to make d:/tmp/source.o > > Then I think it will work. Give it a try, and good luck. Hmm, good idea. But, alas d:/tmp/source.o does exist, so make should have proceeded with the echo command. To examine w/o such a contrived example: Makefile: file.exe: d\:/tmp/file.c gcc d:/tmp/file.c -o file coff2exe file Produces: make.exe: *** No rule to make target `d\:/tmp/file.c'. Stop. If one adds a "d\:/tmp/file.c:" echo rules: Makefile: file.exe: d\:/tmp/file.c gcc d:/tmp/file.c -o file coff2exe file d\:/tmp/file.c: @echo Rules to Make d\:/tmp/source.c or d:/tmp/source.c Produces: Rules to Make d\:/tmp/source.c or d:/tmp/source.c gcc d:/tmp/file.c coff2exe file At which one then throws up thier arms and yells "Great!!", until one runs make again w/o making any changes. Gmake does the compile again. No much of a problem at this size of make file, but if the project has 20 to 40 source files it is. It apears that the d\:/tmp/source.c is just being treated as a dummy target. To test change to foobar: Makefile: file.exe: foobar gcc d:/tmp/file.c -o file coff2exe file foobar: @echo Rules to Make d\:/tmp/file.c or d:/tmp/file.c Produces: Rules to Make d\:/tmp/file.c or d:/tmp/file.c gcc d:/tmp/file.c -o file coff2exe file When run again it does the same thing. Oh well. Eric, you got me a lot closer to a solution, thank your. But still not quit there. On another note: Has anyone been looking at a gnu make source fix for this. I've just started looking. I see some changes that would be needed to be made to read.c around lines 657 to 672 (v3.69 files). But I also see that this could possibly break some of the other uses of the ':' in gmakefiles, of which I'm not very familiar and thus couldn't easily build tests for. Anyways, Is anyone working on a patch? Potter rri!potter AT vtserf DOT cc DOT vt DOT edu