#Buildtemplate for m68k subdirectories

#include ../../buildprefix

OBJSUFFIX = b
MACHINE = m68k
CC = cc68
M68K =
LINT = lint68

# clear the suffix list to avoid extraneous file lookups
.SUFFIXES:
.SUFFIXES: .b .s .c

#ifndef VPATH
VPATH= ../mi
#endif

# Perhaps we should get rid of SPECINCLUDES and just use INCLUDES?
#ifndef SPECINCLUDES
SPECINCLUDES =
#endif
#ifndef INCLUDES
INCLUDES = -I$(VSOURCE)/libc/include/$(MACHINE) -I$(VSOURCE)/libc/include/mi
#endif

#ifndef LIBRARIES
LIBRARIES =
#endif

MIFLAGS = -O -v$(Xx)V
MDFLAGS = -r

# normal compile of a module
.c.b:
	$(CC) $(MIFLAGS) $(SPECINCLUDES) $(INCLUDES) -c $*.c

# how to make an assembly file (Not deleting it or assembling it)
.c.s:
	$(CC) $(MIFLAGS) $(SPECINCLUDES) $(INCLUDES) -S $*.c

# how to make an assembly listing
.c.ls:
	$(CC) $(MIFLAGS) $(SPECINCLUDES) $(INCLUDES) -c -L $*.c
