1# $NetBSD: Makefile,v 1.5 2010/02/03 15:34:38 roy Exp $ 2 3.include <bsd.own.mk> 4 5PROG= top 6BINDIR= /usr/bin 7 8TOPDIR=${.CURDIR}/../dist 9.PATH: ${TOPDIR} ${TOPDIR}/machine 10 11WARNS= 4 12 13CPPFLAGS+=-I${.CURDIR} -I${TOPDIR} -I. 14SRCS= color.c commands.c display.c hash.c screen.c \ 15 top.c username.c utils.c version.c m_netbsd.c 16DPSRCS+=sigdesc.h config.h 17 18LDADD+= -lterminfo -lm -lkvm -lutil 19DPADD+= ${LIBTERMINFO} ${LIBM} ${LIBKVM} ${LIBUTIL} 20 21sigdesc.h: ${TOPDIR}/sigconv.awk ${DESTDIR}/usr/include/sys/signal.h 22 ${_MKTARGET_CREATE} 23 ${TOOL_AWK} -f ${TOPDIR}/sigconv.awk \ 24 ${DESTDIR}/usr/include/sys/signal.h > ${.TARGET} 25CLEANFILES+= sigdesc.h top.1 config.h 26 27top.1: top.1.in 28 ${TOOL_SED} -e s/@DEFAULT_TOPN@/-1/ \ 29 -e s/@DEFAULT_DELAY@/5/ \ 30 -e s/@HAVE_GETOPT_LONG@/1/ \ 31 -e s/@ENABLE_KILL@/1/ \ 32 -e s/@MAN_SUPPLEMENT@// < $? > $@ 33 34commands.c: sigdesc.h 35 36config.h: config.h.in 37 ${TOOL_SED} -e s/@MACHINE@/${MACHINE}/ < $? > $@ 38 39.include <bsd.prog.mk> 40