Add WITHOUT_UTMPX switch to the build system.

This knob removes the tools that are exclusively used to view and
maintain the databases maintained by utmpx, namely last, users, who,
wtmpcvt, ac, lastlogin and utxrm.

The tool w is not in this list, because it has some other functionality
which is unrelated to utmpx; it is hardlinked to the uptime tool.
This commit is contained in:
Ed Schouten 2011-06-17 21:30:21 +00:00
parent 2663175a9e
commit 9f0c9022c2
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=223209
6 changed files with 50 additions and 10 deletions

View file

@ -2,7 +2,12 @@
.include <bsd.own.mk>
FILES= 200.accounting \
999.local
FILES= 999.local
# NB: keep these sorted by MK_* knobs
.if ${MK_UTMPX} != "no"
FILES+= 200.accounting
.endif
.include <bsd.prog.mk>

View file

@ -383,6 +383,7 @@ __DEFAULT_YES_OPTIONS = \
TEXTPROC \
TOOLCHAIN \
USB \
UTMPX \
WIRELESS \
WPA_SUPPLICANT_EAPOL \
ZFS \

View file

@ -3326,6 +3326,24 @@ OLD_FILES+=usr/share/man/man8/telnetd.8.gz
# to be filled in
#.endif
.if ${MK_UTMPX} == no
OLD_FILES+=etc/periodic/monthly/200.accounting
OLD_FILES+=usr/bin/last
OLD_FILES+=usr/bin/users
OLD_FILES+=usr/bin/who
OLD_FILES+=usr/bin/wtmpcvt
OLD_FILES+=usr/sbin/ac
OLD_FILES+=usr/sbin/lastlogin
OLD_FILES+=usr/sbin/utxrm
OLD_FILES+=usr/share/man/man1/last.1.gz
OLD_FILES+=usr/share/man/man1/users.1.gz
OLD_FILES+=usr/share/man/man1/who.1.gz
OLD_FILES+=usr/share/man/man1/wtmpcvt.1.gz
OLD_FILES+=usr/share/man/man8/ac.8.gz
OLD_FILES+=usr/share/man/man8/lastlogin.8.gz
OLD_FILES+=usr/share/man/man8/utxrm.8.gz
.endif
.if ${MK_WIRELESS} == no
OLD_FILES+=etc/regdomain.xml
OLD_FILES+=usr/sbin/ancontrol

View file

@ -0,0 +1,10 @@
.\" $FreeBSD$
Set to not build user accounting tools such as
.Xr last 1 ,
.Xr users 1 ,
.Xr who 1 ,
.Xr wtmpcvt 1 ,
.Xr ac 8 ,
.Xr lastlogin 8
and
.Xr utxrm 8 .

View file

@ -74,7 +74,6 @@ SUBDIR= alias \
ktrace \
ktrdump \
lam \
last \
lastcomm \
ldd \
leave \
@ -170,7 +169,6 @@ SUBDIR= alias \
unzip \
units \
unvis \
users \
uudecode \
uuencode \
vi \
@ -182,10 +180,8 @@ SUBDIR= alias \
what \
whereis \
which \
who \
whois \
write \
wtmpcvt \
xargs \
xinstall \
${_xlint} \
@ -338,6 +334,13 @@ SUBDIR+= usbhidaction
SUBDIR+= usbhidctl
.endif
.if ${MK_UTMPX} != "no"
SUBDIR+= last
SUBDIR+= users
SUBDIR+= who
SUBDIR+= wtmpcvt
.endif
.include <bsd.arch.inc.mk>
SUBDIR:= ${SUBDIR:O}

View file

@ -3,8 +3,7 @@
.include <bsd.own.mk>
SUBDIR= ac \
adduser \
SUBDIR= adduser \
arp \
bootparamd \
burncd \
@ -35,7 +34,6 @@ SUBDIR= ac \
inetd \
iostat \
kldxref \
lastlogin \
mailwrapper \
makefs \
manctl \
@ -90,7 +88,6 @@ SUBDIR= ac \
trpt \
tzsetup \
ugidfw \
utxrm \
vipw \
wake \
watch \
@ -299,6 +296,12 @@ SUBDIR+= usbconfig
SUBDIR+= usbdump
.endif
.if ${MK_UTMPX} != "no"
SUBDIR+= ac
SUBDIR+= lastlogin
SUBDIR+= utxrm
.endif
.if ${MK_WIRELESS} != "no"
SUBDIR+= ancontrol
SUBDIR+= wlandebug