87913a5eba6e60d953d116d95b5d165862f2cf25
[idzebra-moved-to-github.git] / util / Makefile.in
1 # Copyright (C) 1994-1998, Index Data ApS
2 # All rights reserved.
3 # Sebastian Hammer, Adam Dickmeiss
4 # $Id: Makefile.in,v 1.1 1998-09-02 14:15:37 adam Exp $
5
6 SHELL=/bin/sh
7
8 CC=@CC@
9 CPP=@CPP@
10 RANLIB=@RANLIB@
11 CDEFS=@DEFS@ @ODEFS@
12 LIBS=@LIBS@
13
14 YAZLIB=../../yaz/lib/libyaz.a
15 YAZINC=-I../../yaz/include
16
17 INCLUDE=-I../include $(YAZINC)
18 TPROG=opt-test
19 DEFS=$(CDEFS) $(INCLUDE) -DUSE_CRYPT=0
20 LIB=../lib/zebrautl.a
21 PO = res.o charmap.o zebramap.o passwddb.o
22
23 all: $(LIB)
24
25 alll: res-test all passtest
26
27 res-test: res-test.o $(LIB) 
28         $(CC) -o res-test res-test.o $(LIB) $(YAZLIB)
29
30 passtest: passtest.o $(LIB) 
31         $(CC) -o passtest passtest.o $(LIB) $(YAZLIB) -lcrypt
32
33 $(LIB): $(PO)
34         rm -f $(LIB)
35         ar qc $(LIB) $(PO)
36         $(RANLIB) $(LIB)
37
38 .c.o:
39         $(CC) -c $(DEFS) $(CFLAGS) $<
40
41 clean:
42         rm -f *.[oa] res-test core mon.out gmon.out errlist
43
44 depend:
45         sed '/^#Depend/q' <Makefile >Makefile.tmp
46         $(CPP) $(DEFS) -M *.c >>Makefile.tmp
47         mv -f Makefile.tmp Makefile
48
49 #Depend --- DOT NOT DELETE THIS LINE