# implicit rules (Alcyon C floppy version) for PDMAKE

CP	= %c
RM	= %r
ECHO	= %e

# Path to the Alcyon C executables
CPATH	= a:\bin
INC	= a:\include

# C preprocessor
CP68	= cp68.prg
CPFLAGS = -i $(INC)\  

# Pass 1 of the C compiler
C068 	= c068.prg
C0FLAGS = -f	# change to "" if you want to use IEEE
		# floating point and libm instead of libf
		# by Default. Otherwise simply redefine
		# C0FLAGS in your makefile to get the
		# IEEE floating option.

# Pass 2 of the C compiler
C168 	= c168.prg
C1FLAGS =

# Assembler
AS	= as68.prg
ASFLAGS = -l -u -s a:\

#Implicit rules
.SUFFIXES: .prg .68k .o .bin .s .c .pas

.c.o:
    	$(CPATH)\$(CP68) $(CPFLAGS) $< $*.i
        $(CPATH)\$(C068) $*.i $*.1 $*.2 $*.3 $(C0FLAGS)
        $(RM) $*.i
        $(CPATH)\$(C168) $*.1 $*.2 $*.s $(C1FLAGS)
        $(RM) $*.1 $*.2
        $(CPATH)\$(AS) $(ASFLAGS) $*.s
        $(RM) $*.s

.s.o:
        $(CPATH)\$(AS) $(ASFLAGS) $<

# Linker of choice
LINKER = a:\link68.prg

# Relmod
RELMOD = a:\relmod.prg
