# # # Makefile.am: # # Copyright (c) 2009 James McKenzie <20@madingley.org>, # All rights reserved. # # $Id$ # # $Log$ # Revision 1.6 2009/02/08 18:05:29 root # *** empty log message *** # # Revision 1.5 2009/02/08 17:07:09 root # *** empty log message *** # # Revision 1.4 2009/02/08 17:04:47 root # *** empty log message *** # # Revision 1.3 2009/02/08 16:56:18 root # *** empty log message *** # # Revision 1.2 2009/02/08 16:48:21 root # *** empty log message *** # # Revision 1.1 2009/02/08 16:25:32 root # *** empty log message *** # # # # INCLUDES = ${LIBGOBJ_INC} SRCS= libjwg.c version.c cgm.c contour.c version.c xfig.c CPROTO=cproto JWGSRCS=${SRCS} noinst_HEADERS= project.h prototypes.h jwg-tail.h ext_prototypes.h libjwg_a_SOURCES = ${JWGSRCS} libjwg_la_SOURCES = ${JWGSRCS} libjwg_a_CFLAGS = ${AM_CFLAGS} BUILT_SOURCES = version.h jwg.h lib_LIBRARIES=libjwg.a lib_LTLIBRARIES=libjwg.la include_HEADERS=jwg.h AM_CFLAGS=-g libjwg_la_LDFLAGS = \ -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \ -release $(LT_RELEASE) \ -export-dynamic VFD=${srcdir}/.. VF=${shell cat ${VFD}/version-files} VFS=${VF:%=${VFD}/%} VCHK=${shell cat ${VFS} | @MD5SUM@ | @AWK@ '{print $$1 }' } VNUM=${shell @GREP@ ${VCHK} ${VFD}/version-md5sums | @AWK@ '{ print $$2 }' } VDEF=${shell echo `cat ${VFD}/version-major`.`cat ${VFD}/version-minor`.`cat ${VFD}/version-micro` } jwg.h:jwg-head.h ext_prototypes.h jwg-tail.h cat jwg-head.h ext_prototypes.h jwg-tail.h > jwg.h protos: echo > prototypes.h echo > ext_prototypes.h cat jwg-head.h ext_prototypes.h jwg-tail.h > jwg.h ${CPROTO} -v -DINT_PROTOS ${INCLUDES} ${SRCS} > prototypes.tmp mv -f prototypes.tmp prototypes.h ${CPROTO} -v -DEXT_PROTOS ${INCLUDES} ${SRCS} > ext_prototypes.h cat jwg-head.h ext_prototypes.h jwg-tail.h > jwg.h version.h: $(VFD)/version-files $(VFD)/version-major \ $(VFD)/version-minor $(VFD)/version-micro \ $(VFD)/version-md5sums ${VFS} Makefile if [ .${VNUM} = . ]; then \ echo "#define VERSION \"libjwg Version ${VDEF} + Edits\"" > version.h; \ echo ${VDEF}-E > version-num; \ else \ echo "#define VERSION \"libjwg Version ${VNUM}\"" > version.h; \ echo ${VNUM} > version-num; \ fi