# WARNING: DO NOT EDIT.
# THIS FILE WAS AUTOMATICALLY GENERATED USING THE
# BUILDMAKE PROGRAM.

#
# Makefile for M68000 version of V kernel
# Tim Mann, April 5, 1982
# 
HOST= m68k
NET=ENET3MEG
MDNETOBJECTS=$(MD3MEGOBJECTS)
VINCL= ../../libc/include
MI= ../mi

OBJECTS= config.b machine.b serial.b timer.b trap.b \
	memory.b exception.b console.b cbuff.b mice.b smimouse.b
MD3MEGOBJECTS=ether3meg.b
MD10MEGOBJECTS=ether10meg.b

C68FLAGS =  -DMC68000 -I../$(HOST) -O -D$(NET) -V

# first, define the world of 68000s
.SUFFIXES: .b .ls .a68 .c

# how to compile a 68000 file
.c.b:
	cc68 $(C68FLAGS) -c $*.c 

# how to make an assembly file (Not deleting it or assembling it)
.c.s:
	cc68 $(C68FLAGS) -S $*.c

# how to make an assembly listing
.c.ls:
	cc68 $(C68FLAGS) -c -L $*.c

#END of world of 68000's

#Compile everything that needs it
all: $(OBJECTS) $(MDNETOBJECTS)

$(MI)/dm.h: config.h $(VINCL)/Vio.h
	touch $(MI)/dm.h
$(MI)/process.h: config.h machine.h $(VINCL)/Venviron.h
	touch $(MI)/process.h

ether10meg.b: ether10meg.c $(VINCL)/Vethernet.h interrupt.h ether10meg.h \
        $(MI)/dm.h $(VINCL)/Vikc.h

ether3meg.b: ether3meg.c $(VINCL)/Venviron.h $(VINCL)/Vethernet.h \
	interrupt.h ether3meg.h $(MI)/dm.h $(VINCL)/Vikc.h

config.b: config.c config.h $(VINCL)/Vdevicetypes.h

machine.b: machine.c $(MI)/process.h memory.h

serial.b: serial.c interrupt.h cbuff.h $(MI)/dm.h $(MI)/mouse.h \
	$(VINCL)/Vserial.h

timer.b: timer.c interrupt.h $(MI)/dm.h timer.h $(MI)/mouse.h

trap.b: trap.c

memory.b: memory.c $(MI)/process.h memory.h interrupt.h $(VINCL)/Vexceptions.h

exception.b: exception.c $(VINCL)/Venviron.h $(VINCL)/Vexceptions.h \
	$(MI)/process.h

console.b: console.c $(VINCL)/Venviron.h $(VINCL)/Vserial.h \
	$(VINCL)/Vteams.h $(MI)/dm.h $(MI)/process.h machine.h cbuff.h

cbuff.b: cbuff.c cbuff.h

mice.b: mice.c $(VINCL)/Venviron.h machine.h

smimouse.b: smimouse.c

clean:
	rm -f *.o *.b *.s *.ls *BAK *CKP .emacs* .net*

build:
	buildmake.sh

xbuild:
	buildmake.sh -DX=1
