SHELL = /bin/sh
SUBDIRS = balls bars sx

default:
	@echo Please invoke this makefile using sdssmake. >&2
	@exit 1

install:
	@if [ "$(SDSSQT_DIR)" = "" ]; then \
		echo You have not specified a destination directory >&2; \
		exit 1; \
	fi

	cp Makefile *.gif $(SDSSQT_DIR)/images
	for d in $(SUBDIRS); do \
		mkdir $(SDSSQT_DIR)/images/$$d; \
		cp $$d/*.gif $(SDSSQT_DIR)/images/$$d; \
	done

clean:
	- /bin/rm -f *~ .*~ core *.elc *.bak *.orig *.old .\#* \#*\#
	for d in $(SUBDIRS); do \
		(cd $$d; \
		/bin/rm -f *~ .*~ core *.elc *.bak *.orig *.old .\#* \#*\# ); \
	done
