# Makefile for SCIX demos. Johan Ihren.

.SUFFIXES:

.SUFFIXES:	.sc .c .o

.sc.o: ;	$(SCC) -c $(SCCFLAGS) $*.sc
#		ar r ../libdemo.a $*.o

.c.o: ;		$(SCC) -c $(SCCFLAGS) $*.c
#		ar r ../libdemo.a $*.o

SCCFLAGS  = -O -On -Ob -Og
SCC	  = scc
#SCC	  = /usr/local/bin/scc

SXDSRC = demo.sc hello.sc tracker.sc wheel.sc graphic.sc \
	 bounce.sc fifteen.sc ship.sc util.sc

SXDOBJ = demo.o hello.o tracker.o wheel.o graphic.o \
	 bounce.o fifteen.o ship.o util.o

../libdemo.a:	$(SXDOBJ)
		ar r ../libdemo.a $(SXDOBJ)
		ranlib ../libdemo.a

$(SXDOBJ):	../include/stox.sch ../include/scix.sch

clean: ;	rm -f core *.o demo.c hello.c tracker.c wheel.c graphic.c \
                      bounce.c fifteen.c ship.c util.c *~ SC-TO-C*
