Mercurial > ~darius > hgwebdir.cgi > wh1080
diff Makefile @ 0:9dab44dcb331
Initial commit of Greg's code from http://www.lemis.com/grog/tmp/wh1080.tar.gz
author | Daniel O'Connor <darius@dons.net.au> |
---|---|
date | Tue, 09 Feb 2010 13:44:25 +1030 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Makefile Tue Feb 09 13:44:25 2010 +1030 @@ -0,0 +1,54 @@ +# $Id: Makefile,v 1.6 2009/12/20 00:40:24 grog Exp grog $ +# Makefile for wh-1080 +CC = cc +CFLAGS=-g -Wall -Wno-parentheses -I /usr/local/include +LOADLIBES=-lm -L /usr/local/lib -L /usr/local/lib/mysql -lusb -lmysqlclient + +HDRS= wh1080.h wh1080_dev.h +USRCS= util.c db.c +SRCS= wh1080.c ${USRCS} +DSRCS= local-compare.c ${USRCS} +RSRCS= report.c ${USRCS} +XSRCS= xreport.c ${USRCS} +YSRCS= yreport.c ${USRCS} +ALLSRC= ${SRCS} ${DSRCS} ${RSRCS} ${XSRCS} ${YSRCS} +UOBJS= ${USRCS:.c=.o} +OBJS= ${SRCS:.c=.o} +DOBJS= ${DSRCS:.c=.o} +ROBJS= ${RSRCS:.c=.o} +XOBJS= ${XSRCS:.c=.o} +YOBJS= ${YSRCS:.c=.o} +PROGS= wh1080 xreport yreport local-compare # report + +.c.s: + ${CC} $< -o $@ -S + +all: ${PROGS} + +wh1080: ${OBJS} ${HDRS} + ${CC} ${LOADLIBES} ${OBJS} -o $@ + +report: ${ROBJS} ${HDRS} + ${CC} ${LOADLIBES} ${ROBJS} -o $@ + +xreport: ${XOBJS} ${HDRS} + ${CC} ${LOADLIBES} ${XOBJS} -o $@ + +yreport: ${YOBJS} ${HDRS} + ${CC} ${LOADLIBES} ${YOBJS} -o $@ + +local-compare: ${DOBJS} ${HDRS} + ${CC} ${LOADLIBES} ${DOBJS} -o $@ + +# XXX get this right +DISTFILES = ${SRCS} ${HDRS} Makefile README LICENSE xreport.c yreport.c local-compare.c wundersend db plots web + +clean: + rm -f *~ *.o *.core wh1080 TAGS ${PROGS} + +dist: + echo DISTFILES ${DISTFILES} + tar czvf wh1080.tar.gz ${DISTFILES} + +.c.o: ${HDRS} + cc ${CFLAGS} -c -o $@ $<