Old versions of GILS tables
[yaz-moved-to-github.git] / retrieval / Makefile
1 # $Id: Makefile,v 1.8 1996-10-07 15:29:32 quinn Exp $
2
3 SHELL=/bin/sh
4 RANLIB=ranlib
5 INCLUDE=-I../include -I.
6 DEFS=$(INCLUDE)
7 LIB=../lib/libret.a
8 PO = d1_read.o d1_attset.o d1_tagset.o d1_absyn.o d1_grs.o \
9         d1_sutrs.o d1_varset.o d1_espec.o \
10         d1_doespec.o d1_map.o d1_marc.o d1_write.o d1_expout.o d1_sumout.o \
11         d1_soif.o
12 CPP=$(CC) -E
13
14 all: $(LIB)
15
16 tst: tst.c $(LIB)
17         $(CC) -g -o tst $(INCLUDE) tst.c \
18         ../lib/data1.a $(YAZ)/lib/libyaz.a
19
20 $(LIB): $(PO)
21         rm -f $(LIB)
22         ar qc $(LIB) $(PO)
23         $(RANLIB) $(LIB)
24
25 .c.o:
26         $(CC) -c $(DEFS) $(CFLAGS) $<
27
28 clean:
29         rm -f *.[oa] $(TPROG) core mon.out gmon.out errlist test isam-test issh
30
31 depend: depend2
32
33 depend1:
34         mv Makefile Makefile.tmp
35         sed '/^#Depend/q' <Makefile.tmp >Makefile
36         $(CPP) $(INCLUDE) -M *.c >>Makefile
37         -rm Makefile.tmp
38
39 depend2:
40         $(CPP) $(INCLUDE) -M *.c >.depend       
41
42 ifeq (.depend,$(wildcard .depend))
43 include .depend
44 endif
45
46 #Depend --- DOT NOT DELETE THIS LINE