CC=cc
LINK=link
CFLAGS=-Wp -throwback -IC:,TCPIPLibs: -D__riscos__ -DUSE_RMA
OBJS=getopt.o match.o rinetd.o rma_malloc.o
LDFLAGS=TCPIPLibs:o.unixlib TCPIPLibs:o.inetlib TCPIPLibs:o.socklib5 C:o.stubs

.c.o:
	$(CC) $(DEBUG) $(CFLAGS) -c -o $@ $<

all: $(OBJS)
	$(LINK) -o rinetd $(LDFLAGS) $(OBJS)
	ifthere run:squeeze then squeeze rinetd

clean:
	-wipe o.* ~CF~V
	-wipe rinetd ~CF~V
