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

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

Revision 1.42, Mon Jan 22 21:07:10 2024 UTC (3 months, 3 weeks ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, HEAD
Changes since 1.41: +2 -2 lines

I forgot that chpass(1) and passwd(1) reach-around into libc for
getpwent.c (isn't it horrible), and therefore lack visibility of
the the libc-internal __hash_open() function.  Use -DFORCE_DBOPEN
in chpass/Makefile and passwd/Makefile and adjust getpwent.c to
use the external visible interface.  Is there a better way?

#	$OpenBSD: Makefile,v 1.42 2024/01/22 21:07:10 deraadt Exp $

.include <bsd.own.mk>

PROG=	passwd
SRCS=	local_passwd.c passwd.c getpwent.c \
	pwd_check.c
.PATH:  ${.CURDIR}/../../lib/libc/gen
DPADD+= ${LIBRPCSVC} ${LIBUTIL}
LDADD+= -lrpcsvc -lutil
CFLAGS+= -I${.CURDIR} -DFORCE_DBOPEN

CFLAGS+=-I${.CURDIR}/../../lib/libc/include

BINMODE=4555
BINOWN=root

getpwent.o: getpwent.c
	${COMPILE.c} -UYP -D'DEF_WEAK(x)=asm("")' \
	    ${.CURDIR}/../../lib/libc/gen/getpwent.c

.include <bsd.prog.mk>