4e0fb552db1b805b6f6f37c3ada5921f622d7a8c
[chise/concord.git] / Makefile.in
1 CC = @CC@
2 DEFS = @DEFS@
3 LIBS = @LIBS@
4 CFLAGS  = -I. @CFLAGS@ -c -Wall -Wmissing-prototypes
5
6 LIBTOOL = @LIBTOOL@
7
8 RM      = /bin/rm -f
9 TAR     = tar
10
11
12 ## The default location for installation.  Everything is placed in
13 ## subdirectories of this directory.  The default values for many of
14 ## the variables below are expressed in terms of this one, so you may
15 ## not need to change them.  This defaults to /usr/local.
16 prefix  = @prefix@
17
18 ## Like `prefix', but used for architecture-specific files.
19 exec_prefix = @exec_prefix@
20
21 datadir = @datadir@
22
23 libdir  = @libdir@
24
25 #libexecdir = @libexecdir@
26
27 #localstatedir = @localstatedir@
28
29 sharedstatedir = @sharedstatedir@
30
31 #target = @target@
32
33 top_builddir = @builddir@
34
35
36 INCLUDE_INSTALLDIR = ${prefix}/include
37 LIB_INSTALLDIR  = ${libdir}
38
39 VERSION         = @PACKAGE_VERSION@
40 ABI_VERSION     = 0:0:0
41
42
43 HEADERS = concord.h concord-name.h concord-bdb.h
44 OBJS    = concord.lo concord-bdb.lo name.lo
45
46
47 all:    libconcord.la
48
49 libconcord.la:  $(OBJS)
50         $(LIBTOOL) --mode=link \
51                 $(CC) -o libconcord.la $(OBJS) $(LIBS) \
52                 -rpath ${libdir} -version-info $(ABI_VERSION)
53
54 concord.lo:     concord.c concord.h config.h sysdep.h
55         $(LIBTOOL) $(CC) $(CFLAGS) concord.c
56
57 concord-bdb.lo: concord-bdb.c concord-bdb.h concord-name.h
58         $(LIBTOOL) $(CC) $(CFLAGS) concord-bdb.c
59
60 name.lo:        name.c concord-name.h
61         $(LIBTOOL) $(CC) $(CFLAGS) name.c
62
63
64 install:        install.h install.libs
65
66 install.h:
67         install -c $(HEADERS) $(INCLUDE_INSTALLDIR)
68
69 install.libs:   libconcord.la
70         $(LIBTOOL) install -c libconcord.la $(LIB_INSTALLDIR)
71
72
73 sample: sample.c libconcord.la
74         gcc -Wall -Wmissing-prototypes -o sample sample.c -lconcord
75
76
77 clean:
78         -$(RM) -r *.o *.lo *.so *.la .libs sample
79
80 distclean: clean
81         -$(RM) Makefile config.h config.status config.log
82
83
84 tar:
85         cvs commit
86         sh -c 'cvs tag -R libconcord-`echo $(VERSION) \
87                                 | sed s/\\\\./_/ | sed s/\\\\./_/`; \
88         cd /tmp; \
89         cvs -d :pserver:anonymous@cvs.m17n.org:/cvs/concord \
90                 export -d libconcord-$(VERSION) \
91                 -r libconcord-`echo $(VERSION) | tr . _` libconcord'
92         cd /tmp; $(RM) libconcord-$(VERSION)/.cvsignore ; \
93                 $(TAR) cvzf libconcord-$(VERSION).tar.gz libconcord-$(VERSION)
94         cd /tmp; $(RM) -r libconcord-$(VERSION)