5 # Copyright (c) 2008 James McKenzie <james@fishsoup.dhs.org>,
11 # Revision 1.9 2008/02/13 16:57:29 james
12 # *** empty log message ***
14 # Revision 1.8 2008/02/13 09:12:20 james
15 # *** empty log message ***
17 # Revision 1.7 2008/02/12 22:36:46 james
18 # *** empty log message ***
20 # Revision 1.6 2008/02/09 15:47:28 james
21 # *** empty log message ***
23 # Revision 1.5 2008/02/08 15:06:42 james
24 # *** empty log message ***
26 # Revision 1.4 2008/02/07 01:04:16 james
27 # *** empty log message ***
29 # Revision 1.3 2008/02/07 00:39:13 james
30 # *** empty log message ***
32 # Revision 1.2 2008/02/04 01:32:39 james
33 # *** empty log message ***
35 # Revision 1.1 2008/02/03 16:20:24 james
36 # *** empty log message ***
44 PROJECTHDRS= crt.h tty.h ansi.h vt102.h keys.h history.h ring.h slide.h log.h ipc.h context.h prototypes.h
48 SRCS=ansi.c crt.c html.c libsympathy.c render.c version.c vt102.c tty.c \
49 history.c ring.c ptty.c terminal.c util.c log.c ipc.c slide.c
55 noinst_HEADERS= prototypes.h ${HDRS}
58 libsympathy_a_SOURCES = ${SYMPATHYSRCS}
59 libsympathy_la_SOURCES = ${SYMPATHYSRCS}
61 libsympathy_a_CFLAGS = ${AM_CFLAGS}
63 BUILT_SOURCES = version.h sympathy.h
65 lib_LIBRARIES=libsympathy.a
66 lib_LTLIBRARIES=libsympathy.la
68 include_HEADERS=sympathy.h
72 libsympathy_la_LDFLAGS = \
73 -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
74 -release $(LT_RELEASE) \
78 VF=${shell cat ${VFD}/version-files}
80 VCHK=${shell cat ${VFS} | @MD5SUM@ | @AWK@ '{print $$1 }' }
81 VNUM=${shell @GREP@ ${VCHK} ${VFD}/version-md5sums | @AWK@ '{ print $$2 }' }
82 VDEF=${shell echo `cat ${VFD}/version-major`.`cat ${VFD}/version-minor`.`cat ${VFD}/version-micro` }
86 ${CPROTO} -v ${INCLUDES} ${SRCS} > prototypes.tmp
87 mv -f prototypes.tmp prototypes.h
90 indent -i2 -ts0 ${SRCS} ${HDRS}
92 sympathy.h: ${PROJECTHDRS} sympathy.h.head sympathy.h.tail
93 cat sympathy.h.head ${PROJECTHDRS} sympathy.h.tail > $@ || /bin/rm -f $@
95 version.h: $(VFD)/version-files $(VFD)/version-major \
96 $(VFD)/version-minor $(VFD)/version-micro \
97 $(VFD)/version-md5sums ${VFS} Makefile
98 if [ .${VNUM} = . ]; then \
99 echo "#define VERSION \"libsympathy Version ${VDEF} + Edits\"" > version.h; \
100 echo ${VDEF}-E > version-num; \
102 echo "#define VERSION \"libsympathy Version ${VNUM}\"" > version.h; \
103 echo ${VNUM} > version-num; \