1# @(#)Makefile 8.2 (Berkeley) 4/2/94 2# $FreeBSD$ 3 4.PATH: ${.CURDIR}/../../usr.sbin/pwd_mkdb ${.CURDIR}/../../lib/libc/gen 5 6PROG= chpass 7SRCS= chpass.c edit.c field.c pw_scan.c table.c util.c 8BINOWN= root 9BINMODE=4555 10WARNS?= 5 11.if !defined(NO_NIS) 12CFLAGS+= -DYP 13.endif 14#Some people need this, uncomment to activate 15#CFLAGS+=-DRESTRICT_FULLNAME_CHANGE 16CFLAGS+=-I${.CURDIR}/../../usr.sbin/pwd_mkdb -I${.CURDIR}/../../lib/libc/gen -I. 17 18DPADD= ${LIBCRYPT} ${LIBUTIL} 19LDADD= -lcrypt -lutil 20.if !defined(NO_NIS) 21DPADD+= ${LIBYPCLNT} 22LDADD+= -lypclnt 23.endif 24 25LINKS= ${BINDIR}/chpass ${BINDIR}/chfn 26LINKS+= ${BINDIR}/chpass ${BINDIR}/chsh 27.if !defined(NO_NIS) 28LINKS+= ${BINDIR}/chpass ${BINDIR}/ypchpass 29LINKS+= ${BINDIR}/chpass ${BINDIR}/ypchfn 30LINKS+= ${BINDIR}/chpass ${BINDIR}/ypchsh 31.endif 32 33MLINKS= chpass.1 chfn.1 chpass.1 chsh.1 34.if !defined(NO_NIS) 35MLINKS+= chpass.1 ypchpass.1 chpass.1 ypchfn.1 chpass.1 ypchsh.1 36.endif 37 38beforeinstall: 39.for i in chpass chfn chsh ypchpass ypchfn ypchsh 40 [ ! -e ${DESTDIR}${BINDIR}/$i ] || \ 41 chflags noschg ${DESTDIR}${BINDIR}/$i || true 42.endfor 43 44afterinstall: 45 -chflags schg ${DESTDIR}${BINDIR}/chpass 46 47.include <bsd.prog.mk> 48