1TOP?= .. 2include ${TOP}/iconfig.mk 3 4PROG= test 5SRCS= test.c 6SRCS+= test_hmac_md5.c ../crypt/hmac_md5.c 7 8CFLAGS?= -O2 9CSTD?= c99 10CFLAGS+= -std=${CSTD} 11 12CPPFLAGS+= -I../crypt 13 14T_COMPAT_SRCS= ${COMPAT_SRCS:compat/%=../compat/%} 15T_MD5_SRC= ${MD5_SRC:crypt/%=../crypt/%} 16OBJS+= ${SRCS:.c=.o} ${T_COMPAT_SRCS:.c=.o} ${T_MD5_SRC:.c=.o} 17 18.c.o: 19 ${CC} ${CFLAGS} ${CPPFLAGS} -c $< -o $@ 20 21all: ${PROG} 22 23clean: 24 rm -f ${OBJS} ${PROG} ${PROG}.core ${CLEANFILES} 25 26distclean: clean 27 rm -f .depend 28 29.depend: ${SRCS} ${T_COMPAT_SRCS} ${T_CRYPT_SRCS} 30 ${CC} ${CPPFLAGS} -MM ${SRCS} ${T_COMPAT_SRCS} ${T_CRYPT_SRCS} > .depend 31 32depend: .depend 33 34${PROG}: ${DEPEND} ${OBJS} 35 ${CC} ${LDFLAGS} -o $@ ${OBJS} ${LDADD} 36