Added new sub directories zlayer-{yaz,zdist}.
authorAdam Dickmeiss <adam@indexdata.dk>
Mon, 3 Jul 1995 08:19:34 +0000 (08:19 +0000)
committerAdam Dickmeiss <adam@indexdata.dk>
Mon, 3 Jul 1995 08:19:34 +0000 (08:19 +0000)
Install procedure.

Makefile

index e75edea..d3bfa47 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,34 +1,55 @@
 # Top level Makefile for Email gateway.
 # Europagate, 1994-1995.
 #
-# $Id: Makefile,v 1.21 1995/04/20 15:24:54 quinn Exp $
+# $Id: Makefile,v 1.22 1995/07/03 08:19:34 adam Exp $
 #
 SHELL=/bin/sh
 MAKE=make
-SUBDIR=res+log util ccl fml zlayer kernel
-CFLAGS=-Wall -g -pedantic -ansi 
 #CC=checkergcc
 CPP=$(CC) -E
+LIBDIR=/usr/local/lib/emailgw
 
 # 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=
+# Other libraries libraries needed on some systems
 #NETLIB=-lnsl -lsocket
 
-# For linux
-ZPRE=/home/proj/zdist/zdist102b1-1/libz3950
-ZDEFS=-DLOW_TO_HIGH -Dfar=
+# If you are using YAZ uncomment these lines
+ZACC=zlayer-yaz
+ZINC=-I../../yaz/include
+ZLIB=../../yaz/libyaz.a
+ZDEFS=
+
+# If you are using Zdist uncomment these lines
+#ZACC=zlayer-zdist
+#ZINC=-I/usr/local/emailgw/src/zdist102b1-1/libz3950
+#ZLIB=/usr/local/emailgw/src/zdist102b1-1/libz3950/libz3950.a
+#ZDEFS=-DLOW_TO_HIGH -Dfar=
+
+SUBDIR=res+log util ccl fml $(ZACC) kernel
 
 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
+       for i in $(SUBDIR); do cd $$i; if $(MAKE) CFLAGS="$(CFLAGS)" CC="$(CC)" ZINC="$(ZINC)" $(ZLIB)="$(ZLIB)" 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
+       for i in $(SUBDIR); do cd $$i; if $(MAKE) CFLAGS="$(CFLAGS)" CC="$(CC)" ZINC="$(ZINC)" CPP="$(CPP)" REGEXINC="$(REGEXINC)" ZDEFS="$(ZDEFS)" depend; then cd ..; else exit 1; fi; done
 
+install: 
+       @if [ ! -d $(LIBDIR) ]; then \
+               echo "Making directory $(LIBDIR)"; \
+               mkdir $(LIBDIR); \
+       fi
+       @cd kernel; for i in eti monitor kernel; do \
+               echo "Installing $$i"; \
+               cp $$i $(LIBDIR); chmod +x $(LIBDIR)/$$i; \
+       done
+       @cd kernel; for i in *.res *.bib *.fml; do \
+               echo "Installing $$i"; \
+               cp $$i $(LIBDIR);\
+       done
+               
 clean:
        -rm -f lib/*.a
        for i in $(SUBDIR); do (cd $$i; $(MAKE) clean); done
@@ -42,8 +63,8 @@ cleandepend:
 
 taildepend:
        for i in $(SUBDIR); do (cd $$i; \
-               if sed 's/^if/#if/' <Makefile|sed 's/^include/#include/'| \
-               sed 's/^endif/#endif/' | \
+               if sed 's/^if/#GNUif/'<Makefile|sed 's/^include/#GNUinclude/'| \
+               sed 's/^endif/#GNUendif/' | \
                sed 's/^depend: depend2/depend: depend1/g' | \
                sed '/^#Depend/q' >Makefile.tmp; then \
                mv -f Makefile.tmp Makefile; fi); done
@@ -51,8 +72,8 @@ taildepend:
 gnudepend:
        for i in $(SUBDIR); do (cd $$i; \
                if sed '/^#Depend/q' <Makefile| \
-               sed 's/^#if/if/' |sed 's/^#include/include/'| \
-               sed 's/^#endif/endif/' | \
+               sed 's/^#GNUif/if/' |sed 's/^#GNUinclude/include/'| \
+               sed 's/^#GNUendif/endif/' | \
                sed 's/^depend: depend1/depend: depend2/g' >Makefile.tmp;then \
                mv -f Makefile.tmp Makefile; fi); done