[BACK]Return to Makefile CVS log [TXT][DIR] Up to [local] / src / usr.bin / which

File: [local] / src / usr.bin / which / Makefile (download)

Revision 1.9, Thu May 26 21:24:16 2016 UTC (7 years, 11 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1, OPENBSD_7_0_BASE, OPENBSD_7_0, OPENBSD_6_9_BASE, OPENBSD_6_9, OPENBSD_6_8_BASE, OPENBSD_6_8, OPENBSD_6_7_BASE, OPENBSD_6_7, OPENBSD_6_6_BASE, OPENBSD_6_6, OPENBSD_6_5_BASE, OPENBSD_6_5, OPENBSD_6_4_BASE, OPENBSD_6_4, OPENBSD_6_3_BASE, OPENBSD_6_3, OPENBSD_6_2_BASE, OPENBSD_6_2, OPENBSD_6_1_BASE, OPENBSD_6_1, OPENBSD_6_0_BASE, OPENBSD_6_0, HEAD
Changes since 1.8: +2 -2 lines

Use "cc -E" instead of "cpp".  OK deraadt@ natano@

#	$OpenBSD: Makefile,v 1.9 2016/05/26 21:24:16 millert Exp $

PROG=	which
MAN=	which.1 whereis.1
LINKS=	${BINDIR}/which ${BINDIR}/whereis

check_path_in_man:
	@echo "Checking path expansion in whereis.1"; \
	stdpath=`printf '#include <paths.h>\n_PATH_STDPATH\n' | \
	${CC} -E -P ${CPPFLAGS} - | \
	sed -n 's/^[    ]*"\(.*\)".*/.D1 \1/p'` ; \
	fgrep -xq "$$stdpath" ${.CURDIR}/whereis.1 && { touch $@; exit 0; }; \
	echo "Update the expansion of _PATH_STDPATH in ${.CURDIR}/whereis.1"; \
	exit 1

all: check_path_in_man
CLEANFILES = check_path_in_man

.include <bsd.prog.mk>