Mail Archives: djgpp/2001/03/25/13:26:48
> From: "Brian Christiansen" <brianc23454 AT earthlink DOT net>
> Newsgroups: comp.os.msdos.djgpp
> Date: Sun, 25 Mar 2001 16:38:20 GMT
>
> Right now, my makefile is called proj13.mak and looks like:
>
> proj13.exe: video.o testmain13.o
> gcc -o proj13.exe video.o testmain13.o
> video.o: video.cpp
> gcc -c testmain13.cpp
> testmain13.o
> gcc -c testmain13.cpp
>
> (it doesn't quite look like it, at least in my newsreader, but it is a
> "tab", not just a couple of spaces before the lines call gcc)
>
> when I cd to the directory that this file is in (testmain13.cpp and
> video.cpp are in the same directory) and type "make proj13.exe", I get the
> response:
>
> make.exe: *** No rule to make target `proj13.exe'. Stop.
Try "make -f proj13.mak" instead. By default, Make looks for a file
called `Makefile' in the current directory; if you want another file
name, you need to tell that to Make via the -f option.
Btw, you don't need to tell Make how to create a foo.o file from a
foo.cpp file: Make already knows that. Thus, the first rule in your
Makefile is all you need to get this project to build correctly.
- Raw text -