## the Name of the directory containing all this stuff
HOME= FooFaraw
DESTINATION= /LocalLibrary/BackSpaceViews
## Names of all the screen savers that should be included in the
## binary distribution package (everything in the home directory is
## included in the dist-src)
SAVERS= \
	Desquamate \
	ItJustStopped \
	Lizard \
	PolyFrog \
	Scaled \
	SpiroFrog \
	ChunkScale

GARBAGE= Views FooFarawViews.pkg ../$(HOME).tar.Z *.o *~

clean:
	rm -rf $(GARBAGE)
	rm -rf ../FooFaraw.pkg.tar
	for i in ${SAVERS} none ; do \
	  if [ $$i = none ] ; then continue; fi; \
	  (cd $$i; make clean); \
	done ;

install:
	for i in ${SAVERS} none ; do \
	  if [ $$i = none ] ; then continue; fi; \
	  (cd $$i; make; cp $${i}View.o ${DESTINATION}); \
	done ;

dist-bin:
	rm -rf $(GARBAGE)
	mkdir Views
	for i in ${SAVERS} none ; do \
	  if [ $$i = none ] ; then continue; fi; \
	  (cd $$i; \
	   make; \
	   cp $${i}View.o ../Views); \
	done ;
	/NextApps/Installer.app/package Views FooFarawViews.info
	tar cf ../FooFarawViews.pkg.tar FooFarawViews.pkg

dist-src: clean
	rm -rf $(GARBAGE)
	(cd ..; tar cf - $(HOME) | compress -v - > $(HOME).src.tar.Z)
	
	
	