diff options
author | ru <ru@FreeBSD.org> | 2001-07-12 15:07:30 +0000 |
---|---|---|
committer | ru <ru@FreeBSD.org> | 2001-07-12 15:07:30 +0000 |
commit | e381dd2c3a01207a73528df37bb5ffaf25ea6060 (patch) | |
tree | 56cb8dfb96f21c3d5f519268d54942c859b4382e /usr.bin/top/Makefile | |
parent | ccc325a5ee60240bcef17c6a4339cac491f190da (diff) | |
download | FreeBSD-src-e381dd2c3a01207a73528df37bb5ffaf25ea6060.zip FreeBSD-src-e381dd2c3a01207a73528df37bb5ffaf25ea6060.tar.gz |
Generate top.local.h and manpage dynamically, with sed(1) script.
The generated manpage will now describe the actual behavior of
top(1) WRT how many processes it displays. This also eliminates
all troff(1) warnings.
Diffstat (limited to 'usr.bin/top/Makefile')
-rw-r--r-- | usr.bin/top/Makefile | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/usr.bin/top/Makefile b/usr.bin/top/Makefile index ce2db6e..ebd5c48 100644 --- a/usr.bin/top/Makefile +++ b/usr.bin/top/Makefile @@ -4,7 +4,7 @@ PROG= top TOPDIR= ${.CURDIR}/../../contrib/top .PATH: ${TOPDIR} -CFLAGS+= -DHAVE_GETOPT -I${.CURDIR} -I${TOPDIR} -DORDER +CFLAGS+= -DHAVE_GETOPT -I${.CURDIR} -I${TOPDIR} -I. -DORDER # # The table size should be a prime number approximately twice as @@ -16,13 +16,25 @@ CFLAGS+= -D"Table_size=${TOP_TABLE_SIZE}" .endif SRCS= commands.c display.c machine.c screen.c top.c \ - username.c utils.c version.c + username.c utils.c version.c top.local.h -CLEANFILES+= top.1 +CLEANFILES+= top.local.h top.x top.1 DPADD= ${LIBTERMCAP} ${LIBM} ${LIBKVM} LDADD= -ltermcap -lm -lkvm -top.1: ${TOPDIR}/top.X top.local.1 +top.1: top.x top.local.1 cat ${.ALLSRC} > top.1 +.SUFFIXES: .X .x .H .h + +.X.x .H.h: + @${ECHO} Making ${.TARGET} from ${.IMPSRC} + @sed -e's,%LoadMax%,5.0,g' \ + -e's,%TableSize%,20011,g' \ + -e's,%NominalTopn%,18,g' \ + -e's,%topn%,-1,g' \ + -e's,%delay%,2,g' \ + -e's,%random%,1,g' \ + ${.IMPSRC} > ${.TARGET} + .include <bsd.prog.mk> |