Added @ as hostname alias for INADDR ANY.
[yaz-moved-to-github.git] / comstack / Makefile
1 # Copyright (C) 1994, Index Data I/S 
2 # All rights reserved.
3 # Sebastian Hammer, Adam Dickmeiss
4 # $Id: Makefile,v 1.1 1995-06-14 09:58:19 quinn Exp $
5
6
7 LIBDIR=../lib
8
9 #LIBOSI=../../xtimosi/src/libmosi.a $(LIBDIR)/librfc.a
10 #XMOSI=xmosi.o
11
12 SHELL=/bin/sh
13 INCLUDE=-I../include -I. -I../../xtimosi/src
14 LIBINCLUDE=-L$(LIBDIR) -L../../xtimosi/src
15 #CFLAGS=-Wall -pedantic -g
16 #CFLAGS=-g
17 DEFS=$(INCLUDE) -DRPN_QUERY # -DTRACE_TCPIP
18 LIB= $(LIBDIR)/libcomstack.a 
19 LIBS=$(LIBDIR)/libasn.a $(LIBDIR)/libodr.a $(LIBDIR)/libcomstack.a \
20          ../lib/ccl.a $(LIBDIR)/libutil.a $(LIBMOSI)
21 PO = comstack.o tcpip.o $(XMOSI)
22 CPP=$(CC) -E
23 #CC=checkergcc
24
25 all: $(LIBDIR) $(LIB)
26
27 cli: tst.o $(LIB)
28         $(CC) $(CFLAGS) $(LIBINCLUDE) -o cli tst.o $(LIBINCLUDE) $(LIBS)
29
30 alll:
31
32 $(LIB): $(PO)
33         rm -f $(LIB)
34         ar qc $(LIB) $(PO)
35         ranlib $(LIB)
36
37 $(LIBDIR):
38         mkdir $(LIBDIR)
39 .c.o:
40         $(CC) -c $(DEFS) $(CFLAGS) $<
41
42 clean:
43         rm -f *.[oa] test core mon.out gmon.out errlist tst cli
44
45 depend: depend2
46
47 depend1:
48         sed '/^#Depend/q' <Makefile >Makefile.tmp
49         $(CPP) $(DEFS) -M *.c >>Makefile.tmp
50         mv -f Makefile.tmp Makefile
51
52 depend2:
53         $(CPP) $(INCLUDE) -M *.c >.depend       
54
55 ifeq (.depend,$(wildcard .depend))
56 include .depend
57 endif
58
59 #Depend --- DOT NOT DELETE THIS LINE