# Top level Makefile for Email gateway. # Europagate, 1994-1995. # # $Id: Makefile,v 1.20 1995/04/17 09:31:02 adam Exp $ # SHELL=/bin/sh MAKE=make SUBDIR=res+log util ccl fml zlayer kernel CFLAGS=-Wall -g -pedantic -ansi CPP=$(CC) -E # GNU regex package location #REGEXOBJ=/usr/local/gnu/regex-0.12/regex.o #REGEXINC=-I/usr/local/gnu/regex-0.12 # For sun-sparc-solaris #ZPRE=/usr/local/emailgw/src/zdist102b1-1/libz3950 #ZDEFS=-DHIGH_TO_LOW -Dfar= #NETLIB=-lnsl -lsocket # For linux ZPRE=/home/proj/zdist/zdist102b1-1/libz3950 ZDEFS=-DLOW_TO_HIGH -Dfar= all: for i in $(SUBDIR); do cd $$i; if $(MAKE) CFLAGS="$(CFLAGS)" CC="$(CC)" ZPRE="$(ZPRE)" CPP="$(CPP)" NETLIB="$(NETLIB)" REGEXOBJ="$(REGEXOBJ)" REGEXINC="$(REGEXINC)" ZDEFS="$(ZDEFS)"; then cd ..; else exit 1; fi; done dep depend: for i in $(SUBDIR); do cd $$i; if $(MAKE) CFLAGS="$(CFLAGS)" CC="$(CC)" ZPRE="$(ZPRE)" CPP="$(CPP)" REGEXINC="$(REGEXINC)" ZDEFS="$(ZDEFS)" depend; then cd ..; else exit 1; fi; done clean: -rm -f lib/*.a for i in $(SUBDIR); do (cd $$i; $(MAKE) clean); done distclean: clean cleandepend cleandepend: for i in $(SUBDIR); do (cd $$i; \ if sed '/^#Depend/q' Makefile.tmp; then \ mv -f Makefile.tmp Makefile; fi; rm -f .depend); done taildepend: for i in $(SUBDIR); do (cd $$i; \ if sed 's/^if/#if/' Makefile.tmp; then \ mv -f Makefile.tmp Makefile; fi); done gnudepend: for i in $(SUBDIR); do (cd $$i; \ if sed '/^#Depend/q' Makefile.tmp;then \ mv -f Makefile.tmp Makefile; fi); done wc: wc `find . -name '*.[ch]'`