SCOPTS = MCCONS STRMERGE UNSCHAR NOSTKCHK OPTIMIZE

XFH   = XFH-Handler
OBJS  = CFS.o DoDOS.o Packet.o lock.o dosfunc.o file.o pack.o misc.o \
packfunc.o xobj.o xpk.o options.o arexx.o gui.o dossupport.o
XFHD  = XFH-DebugHandler
DOBJS = CFS.d DoDOS.o Packet.d lock.d dosfunc.d file.d pack.d misc.d \
packfunc.d xobj.d xpk.d options.d arexx.d gui.d dossupport.o

.c.o:
	sc $*.c $(SCOPTS) OBJNAME=$*.o

.c.d:
	sc $*.c $(SCOPTS) DEFINE=DEBUG OBJNAME=$*.d

.a.o:
	asm -iSprachen:Include/include_i $*.a

$(XFH): $(OBJS)
	slink FROM $(OBJS) SC SD ND LIB LIB:sc.lib LIB:amiga.lib TO $(XFH) NOICONS

$(XFHD): $(DOBJS)
	slink FROM $(DOBJS) SC SD ND LIB LIB:debug.lib LIB:sc.lib LIB:amiga.lib TO $(XFHD) NOICONS

All: $(XFH) $(XFHD)

