50 -${MAKE} compile |
54 -${MAKE} compile |
51 |
55 |
52 compile: ${OBJ} |
56 compile: ${OBJ} |
53 ${LD} -o ${BIN} ${OBJ} ${LDFLAGS} |
57 ${LD} -o ${BIN} ${OBJ} ${LDFLAGS} |
54 |
58 |
55 setup: |
59 setup: ${BUILDDIR} |
56 mkdir -p ${BUILDDIR} |
|
57 rm -f ${BUILDDIR}cline.o |
60 rm -f ${BUILDDIR}cline.o |
58 mv cline.h cline.src |
61 mv ${SRCDIR}cline.h ${SRCDIR}cline.src |
59 cat cline.src | sed "s/VERSION.*/VERSION=\"${VERSION_PREFIX}$(shell hg identify -n) ($(shell hg identify -i))\";/g" > cline.h |
62 cat ${SRCDIR}cline.src | sed "s/VERSION.*/VERSION=\"${VERSION_PREFIX}$(shell hg identify -n) ($(shell hg identify -i))\";/g" > ${SRCDIR}cline.h |
|
63 |
|
64 ${BUILDDIR}: |
|
65 mkdir ${BUILDDIR} |
60 |
66 |
61 teardown: |
67 teardown: |
62 rm -f cline.h |
68 rm -f ${SRCDIR}cline.h |
63 mv cline.src cline.h |
69 mv ${SRCDIR}cline.src ${SRCDIR}cline.h |
64 |
70 |
65 ${BUILDDIR}%.o: %.c |
71 ${BUILDDIR}%.o: ${SRCDIR}%.c |
66 ${CC} ${CFLAGS} -c -o ${BUILDDIR}$*.o $< |
72 ${CC} ${CFLAGS} -c -o ${BUILDDIR}$*.o $< |
67 |
73 |
68 clean: |
74 clean: |
69 rm -f ${BUILDDIR}*.o |
75 rm -f ${BUILDDIR}*.o |
70 |
76 |