Minor changes.
[egate.git] / kernel / Makefile
1 # Makefile for Email gateway CCL
2 # Europagate, 1995
3 #
4 # $Log: Makefile,v $
5 # Revision 1.30  1996/05/31 08:02:26  adam
6 # Minor changes.
7 #
8 # Revision 1.29  1996/05/22 08:37:21  adam
9 # Removed CFLAGS definition.
10 #
11 # Revision 1.28  1996/01/24 08:28:07  adam
12 # Fix.
13 #
14 # Revision 1.27  1995/07/05  10:20:06  adam
15 # Z definitions duplicated from ../Makefile.
16 #
17 # Revision 1.26  1995/07/03  08:20:12  adam
18 # More help information and better diagnostics.
19 #
20 # Revision 1.25  1995/05/19  13:25:58  adam
21 # Bug fixes. Better command line options.
22 #
23 # Revision 1.24  1995/05/03  12:18:46  adam
24 # This code ran on dtbsun. Minor changes.
25 #
26 # Revision 1.23  1995/05/03  07:37:29  adam
27 # CCL commands stop/continue implemented. New functions gw_res_{int,bool}
28 # are used when possible.
29 #
30 # Revision 1.22  1995/05/01  12:43:26  adam
31 # First work on resource monitor program.
32 #
33 # Revision 1.21  1995/04/20  16:10:45  adam
34 # Modified to work with non-blocking zass-api. Not using non-blocking
35 # facility yet.
36 #
37 # Revision 1.20  1995/04/20  15:24:59  quinn
38 # *** empty log message ***
39 #
40 # Revision 1.19  1995/04/19  16:08:20  adam
41 # Minor changes.
42 #
43 # Revision 1.18  1995/04/19  16:01:57  adam
44 # Some hacks to get the FIFO communication work!! Isn't reliable.
45 # Resource gw.account added - default account info.
46 #
47 # Revision 1.17  1995/04/19  10:46:17  adam
48 # Persistency works much better now. New command: status - history-like
49 #
50 # Revision 1.16  1995/04/19  07:30:56  adam
51 # First work on Z39.50 persistence.
52 #
53 # Revision 1.15  1995/04/17  11:27:29  quinn
54 # Smallish
55 #
56 # Revision 1.14  1995/04/17  09:34:23  adam
57 # Timeout (idletime) adjustable. Minor changes in kernel.
58 #
59 # Revision 1.13  1995/03/27  12:51:04  adam
60 # New log level in use: GW_LOG_ERRNO.
61 #
62 # Revision 1.12  1995/03/27  08:23:57  adam
63 # First use of gip interface and gw-db.
64 # First work on eti program.
65 #
66 # Revision 1.11  1995/03/03  17:19:09  adam
67 # Smarter presentation. Bug fix in email header interpretation.
68 #
69 # Revision 1.10  1995/03/01  14:32:24  adam
70 # Better diagnostics. Default is, that only one database selected when
71 # several are known.
72 #
73 # Revision 1.9  1995/02/23  08:32:14  adam
74 # Changed header.
75 #
76 # Revision 1.7  1995/02/22  08:51:34  adam
77 # Output function can be customized in fml, which is used to print
78 # the reply to reply_fd.
79 #
80 # Revision 1.6  1995/02/21  14:00:08  adam
81 # Minor changes.
82 #
83 # Revision 1.5  1995/02/21  12:11:59  adam
84 # Diagnostic record with error info. observed.
85 #
86 # Revision 1.4  1995/02/20  21:16:16  adam
87 # FML support. Bug fixes. Profile for drewdb.
88 #
89 # Revision 1.3  1995/02/17  09:08:35  adam
90 # Reply with subject. CCL base command implemented.
91 #
92 # Revision 1.2  1995/02/16  18:35:07  adam
93 # First use of Zdist library. Search requests are supported.
94 # Present requests are not supported yet.
95 #
96 # Revision 1.1  1995/02/15  17:45:29  adam
97 # First version of email gateway kernel. Email requests are read
98 # from stdin. The output is transferred to an MTA if 'From' is
99 # found in the header - or stdout if absent. No Z39.50 client is used.
100 #
101 #
102 SHELL=/bin/sh
103
104 ZINC=-I../../yaz/include
105 ZLIB=../../yaz/lib/libyaz.a
106 ZDEFS=
107
108 INCLUDE=-I../include
109 CPP=$(CC) -E
110 DEFS=$(INCLUDE) -DUSE_FML=1
111
112 PROG1=kernel
113 O1=main.o urp.o persist.o
114 USELIBS1=../lib/ccl.a ../lib/fml.a ../lib/libzass.a ../lib/libres+log.a \
115 ../lib/util.a $(REGEXOBJ)
116
117 PROG2=eti
118 O2=eti.o
119 USELIBS2=../lib/libres+log.a ../lib/util.a 
120
121 PROG3=monitor
122 O3=monitor.o
123 USELIBS3=../lib/libres+log.a ../lib/util.a 
124
125 all: $(PROG1) $(PROG2) $(PROG3)
126
127 $(PROG1): $(O1) $(USELIBS1)
128         $(CC) $(CFLAGS) -o $(PROG1) $(O1) $(USELIBS1) $(ZLIB) $(ELIB)
129
130 $(PROG2): $(O2) $(USELIBS2)
131         $(CC) $(CFLAGS) -o $(PROG2) $(O2) $(USELIBS2) $(ZLIB) $(ELIB)
132
133 $(PROG3): $(O3) $(USELIBS3)
134         $(CC) $(CFLAGS) -o $(PROG3) $(O3) $(USELIBS3) $(ZLIB) $(ELIB)
135
136 .c.o:
137         $(CC) -c $(DEFS) $(CFLAGS) $<
138
139 clean:
140         rm -f *.log *.[oa] $(PROG1) $(PROG2) $(PROG3)
141         rm -f core mon.out gmon.out errlist *~ fifo.*
142
143 depend: depend2
144
145 depend1:
146         sed '/^#Depend/q' <Makefile >Makefile.tmp
147         $(CPP) $(DEFS) -M *.c >>Makefile.tmp
148         mv -f Makefile.tmp Makefile
149
150 depend2:
151         $(CPP) $(DEFS) -M *.c >.depend  
152
153 #GNU make style depend
154 ifeq (.depend,$(wildcard .depend))
155 include .depend
156 endif
157
158 #Depend --- DOT NOT DELETE THIS LINE