DESTDIR=/usr/local/

ocorbackend: ocor.pp transformations.pp
	fpc ocor.pp -oocorbackend

ocor: ocorbackend

all: transformations ocor

transformations: transformations.pp
	fpc transformations.pp

cleantmp:
	rm -f /tmp/ocorsdl-user.0
	rm -f /tmp/frocor-uds

clean: cleantmp
	rm -f *~ ppas.sh *.o

distclean: clean
	rm -f *.ppu
	rm -f *.ppu
	rm -f ocorbackend

mrproper: distclean

install: ocorbackend
	install -c -d $(DESTDIR)/bin
	install -c ocorbackend $(DESTDIR)/bin/

#debugging:
crashed: cleantmp
	killall quint; exit 0
	killall genuds; exit 0
	killall -9 ocorbackend; exit 0
	killall -9 ocor-sdlclient; exit 0
	killall -9 quint; exit 0
	killall -9 genuds; exit 0
