# $Source: F:/DJGPP/EXAMPLES/C/MULTI/RCS/makefile $
# $Revision: 1.2 $
# $Date: 1997/05/14 06:18:29 $
# $Author: PHIL $
# $Locker:  $
#
# makefile to compile, link and run the multiple-file example program


# the default (i.e first) go target runs the program
go:		multi.exe
		multi


# the multi.exe target creates/updates multi.exe & multi (COFF file)
# by linking multi.o, func1.o and func2.o
multi.exe:	multi.o func1.o func2.o
		gcc -Wall -o multi multi.o func1.o func2.o


# the multi.o target creates/updates multi.o by compiling multi.c
multi.o:	multi.c multi.h
		gcc -Wall -c multi.c


# the func1.o target creates/updates func1.o by compiling func1.c
func1.o:	func1.c multi.h
		gcc -Wall -c func1.c


# the func2.o target creates/updates func2.o by compiling func2.c
func2.o:	func2.c multi.h
		gcc -Wall -c func2.c


# the clean target deletes the object-, executable- and COFF-files
clean:
		rm multi multi.o func1.o func2.o multi.exe

