created unix make file for unit test.

This commit is contained in:
skarg
2007-01-22 19:43:17 +00:00
parent c0bbabc27b
commit b52854a073
+31
View File
@@ -0,0 +1,31 @@
#Makefile to build test case
CC = gcc
BASEDIR = .
#CFLAGS = -Wall -I.
# -g for debugging with gdb
#CFLAGS = -Wall -I. -g
CFLAGS = -Wall -I. -Itest -DTEST -DTEST_DATE_TIME -g
SRCS = datetime.c \
test/ctest.c
OBJS = ${SRCS:.c=.o}
TARGET = datetime
all: ${TARGET}
${TARGET}: ${OBJS}
${CC} -o $@ ${OBJS}
.c.o:
${CC} -c ${CFLAGS} $*.c -o $@
depend:
rm -f .depend
${CC} -MM ${CFLAGS} *.c >> .depend
clean:
rm -rf core ${TARGET} $(OBJS) *.bak *.1 *.ini
include: .depend