From: Ming-Dien C. <min...@gm...> - 2008-09-12 11:48:25
|
I use mingw32-make under command line of Windows XP. But the VPATH seems work with only one path, not for multiple path. Here is a simple Makefile: VPATH = code:inc all: Main.c @echo $< and the error msg is: mingw32-make.exe: *** No rule to make target `Main.c', needed by `all'. Stop. It should be that mingw32-make cannot find the file Main.c, nor the target named 'Main.c'. Apply option -p, got the following infor: # VPATH Search Paths # No `vpath' search paths. # No general (`VPATH' variable) search path. Just simplify the VPATH to only one path (Main.c locates under the 'code' directory): VPATH = code all: Main.c @echo $< it works fine. and infor of option -p : # VPATH Search Paths # No `vpath' search paths. # General (`VPATH' variable) search path: # code Do I misunderstand any thing ? |
From: Dave K. <dav...@ar...> - 2008-09-12 12:15:58
|
Ming-Dien Chang wrote on 12 September 2008 12:48: > I use mingw32-make under command line of Windows XP. > But the VPATH seems work with only one path, not for multiple path. > > Here is a simple Makefile: > > VPATH = code:inc This is windows. Use semicolons to separate the path, a colon indicates a drive letter. > Just simplify the VPATH to only one path (Main.c locates under the 'code' > directory): No colon any more! > Do I misunderstand any thing ? Just that mingw32-make uses windows paths, not posix-style. cheers, DaveK -- Can't think of a witty .sigline today.... |
From: Ming-Dien C. <min...@gm...> - 2008-09-12 12:30:56
|
Thanks for DaveK's response. Actually, I have tried colon, semicolon, and space as the separator, and the results are all the same. On Fri, Sep 12, 2008 at 8:15 PM, Dave Korn <dav...@ar...> wrote: > Ming-Dien Chang wrote on 12 September 2008 12:48: > > > I use mingw32-make under command line of Windows XP. > > But the VPATH seems work with only one path, not for multiple path. > > > > Here is a simple Makefile: > > > > VPATH = code:inc > > This is windows. Use semicolons to separate the path, a colon indicates > a > drive letter. > > > Just simplify the VPATH to only one path (Main.c locates under the 'code' > > directory): > > No colon any more! > > > Do I misunderstand any thing ? > > Just that mingw32-make uses windows paths, not posix-style. > > > cheers, > DaveK > |
From: Greg C. <gch...@sb...> - 2008-09-12 12:47:28
|
[Please don't top post. Here are guidelines for this mailing list: http://article.gmane.org/gmane.comp.gnu.mingw.user/27577 Thanks.] On 2008-09-12 12:30Z, Ming-Dien Chang wrote: > Thanks for DaveK's response. > Actually, I have tried colon, semicolon, and space as the separator, > and the results are all the same. Try the vpath directive, delimiting paths with blank spaces for portability. It is more powerful than the VPATH variable anyway: http://www.gnu.org/software/make/manual/make.html#Selective-Search |
From: Ming-Dien C. <min...@gm...> - 2008-09-15 02:19:57
|
On Fri, Sep 12, 2008 at 8:47 PM, Greg Chicares <gch...@sb...>wrote: > [Please don't top post. Here are guidelines for this mailing list: > http://article.gmane.org/gmane.comp.gnu.mingw.user/27577 > Thanks.] > Thanks for reminder. Try the vpath directive, delimiting paths with blank spaces for > portability. It is more powerful than the VPATH variable anyway: > http://www.gnu.org/software/make/manual/make.html#Selective-Search > > I have tried the VPATH and vpath, and nothing different. mingw32-make still cannot find the prerequisite file. VPATH = code inc vpath %.c code inc all: main.c @echo $< Only path "code" included in VPATH or vpath could locate the prerequisite file (main.c located in code/). I just download mingw32-make, nothing else of MinGW packages. Does it matter ? |