# -----------------------------------------------------------------------------
#	Makefile system to build scrdrv,graphlib and demos. 
# -----------------------------------------------------------------------------
#
#	Copyright (C) 1995 by Andreas Beck,
#			      [becka@sunserver1.rz.uni-duesseldorf.de]
#
# -----------------------------------------------------------------------------
#
#	This program is free software; you can redistribute it and/or modify
#	it under the terms of the GNU General Public License as published by
#	the Free Software Foundation; either version 2, or (at your option)
#	any later version.
#
#	This program is distributed in the hope that it will be useful,
#	but WITHOUT ANY WARRANTY; without even the implied warranty of
#	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#	GNU General Public License for more details.
#
#	You should have received a copy of the GNU General Public License
#	along with this program; see the file COPYING.  If not, write to
#	the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
#
# ----------------------------------------------------------------------------

include driver/.config

SUBDIRS = lib demos
DEBUGFLAGS = -DDEBUG
MAKEFLAGS = --no-print-directory #--silent

.PHONY: all driver

all:	driver
	@set -e; for i in $(SUBDIRS); do $(MAKE) -C $$i all; done

driver:
	$(MAKE) -C driver scrdrv

config:
	$(MAKE) -C driver config

../scrdrv-$(VERSION).tgz:	tar

tar:
	rm -f scrdrv-$(VERSION)
	ln -s . scrdrv-$(VERSION)
	tar cvf - scrdrv-$(VERSION)/ | gzip >../scrdrv-$(VERSION).tgz
	cp doc/scrdrv.lsm ../scrdrv-$(VERSION).lsm

uu:	../scrdrv-$(VERSION).tgz
	(cd ..;\
	uuencode scrdrv-$(VERSION).tgz <scrdrv-$(VERSION).tgz \
	>scrdrv-$(VERSION).tgz.uu)

include .recursive

