Fix several places where tool name has been hardcoded:

install -> ${INSTALL}
    mtree -> ${MTREE_CMD}
    services_mkdb -> ${SERVICES_MKDB_CMD}
    cap_mkdb -> ${CAP_MKDB_CMD}
    pwd_mkdb -> ${PWD_MKDB_CMD}
    kldxref -> ${KLDXREF_CMD}

If you do custom FreeBSD builds you may want to override those
in some cases.

Sponsored by:	Sippy Software, Inc.
This commit is contained in:
sobomax 2019-06-02 23:38:19 +00:00
parent 8b5fc46c35
commit 42285b484e
7 changed files with 13 additions and 8 deletions

View File

@ -887,8 +887,8 @@ MTREEFLAGS+= -W
INSTALLFLAGS+= -h sha256
.endif
.if defined(DB_FROM_SRC) || defined(NO_ROOT)
IMAKE_INSTALL= INSTALL="install ${INSTALLFLAGS}"
IMAKE_MTREE= MTREE_CMD="mtree ${MTREEFLAGS}"
IMAKE_INSTALL= INSTALL="${INSTALL} ${INSTALLFLAGS}"
IMAKE_MTREE= MTREE_CMD="${MTREE_CMD} ${MTREEFLAGS}"
.endif
DESTDIR_MTREEFLAGS= -deU

View File

@ -6,6 +6,7 @@
FILESGROUPS= FILES
NLS_ALIASES= POSIX C \
en_US.US_ASCII C
PWD_MKDB_CMD?= pwd_mkdb
# No need as it is empty and just causes rebuilds since this file does so much.
UPDATE_DEPENDFILE= no

View File

@ -22,6 +22,8 @@
# They have to be listed here so we can build modules outside of the
# src tree.
KLDXREF_CMD?= kldxref
__DEFAULT_YES_OPTIONS = \
AUTOFS \
BHYVE \

View File

@ -348,8 +348,8 @@ afterinstall: _kldxref
.ORDER: _installlinks _kldxref
_kldxref: .PHONY
@if type kldxref >/dev/null 2>&1; then \
${ECHO} kldxref ${DESTDIR}${KMODDIR}; \
kldxref ${DESTDIR}${KMODDIR}; \
${ECHO} ${KLDXREF_CMD} ${DESTDIR}${KMODDIR}; \
${KLDXREF_CMD} ${DESTDIR}${KMODDIR}; \
fi
.endif
.endif # !target(realinstall)

View File

@ -795,8 +795,8 @@ SUBDIR:= ${SUBDIR:N${reject}}
.MAKEFLAGS+= -DNO_XREF
afterinstall: .PHONY
@if type kldxref >/dev/null 2>&1; then \
${ECHO} kldxref ${DESTDIR}${KMODDIR}; \
kldxref ${DESTDIR}${KMODDIR}; \
${ECHO} ${KLDXREF_CMD} ${DESTDIR}${KMODDIR}; \
${KLDXREF_CMD} ${DESTDIR}${KMODDIR}; \
fi
.endif

View File

@ -8,6 +8,7 @@ PROG= login
SRCS= login.c login_fbtab.c
CFLAGS+=-DLOGALL
LIBADD= util pam
CAP_MKDB_CMD?= cap_mkdb
WARNS?= 5
@ -25,7 +26,7 @@ PRECIOUSPROG=
.include <bsd.endian.mk>
afterinstallconfig:
cap_mkdb ${CAP_MKDB_ENDIAN} ${DESTDIR}/etc/login.conf
${CAP_MKDB_CMD} ${CAP_MKDB_ENDIAN} ${DESTDIR}/etc/login.conf
.if defined(NO_ROOT) && defined(METALOG)
echo "./etc/login.conf.db type=file mode=0644 uname=root gname=wheel" | \
cat -l >> ${METALOG}

View File

@ -4,12 +4,13 @@ CONFS= services
PROG= services_mkdb
MAN= services_mkdb.8
SRCS= services_mkdb.c uniq.c extern.h
SERVICES_MKDB_CMD?= ${PROG}
.include <bsd.endian.mk>
.include <src.opts.mk>
.if ${MK_SERVICESDB} != "no"
afterinstallconfig:
services_mkdb ${CAP_MKDB_ENDIAN} -q -o ${DESTDIR}/var/db/services.db \
${SERVICES_MKDB_CMD} ${CAP_MKDB_ENDIAN} -q -o ${DESTDIR}/var/db/services.db \
${DESTDIR}/etc/services
.if defined(NO_ROOT) && defined(METALOG)
echo "./var/db/services.db type=file mode=0644 uname=root gname=wheel" | \