# file: GNUMakefile # # define a target for the application # all: myprog.exe # define a target to link the application # myprog.exe: myprog.o g++ -lm myprog.o -o myprog.exe # define targets to compile the source code # myprog.o: myprog.cc Makefile g++ -O2 -c myprog.cc -o myprog.o # define a target to clean the directory # clean: rm -f myprog.o myprog_00.o myprog.exe # # end of file