svn commit: r278664 - head/usr.bin/chpass
Baptiste Daroussin
bapt at FreeBSD.org
Fri Feb 13 07:51:27 UTC 2015
Author: bapt
Date: Fri Feb 13 07:51:26 2015
New Revision: 278664
URL: https://svnweb.freebsd.org/changeset/base/278664
Log:
Partially revert 278642
On reinstall (overwrite) install(1) does not handle chflags
Reported by: ian
Modified:
head/usr.bin/chpass/Makefile
Modified: head/usr.bin/chpass/Makefile
==============================================================================
--- head/usr.bin/chpass/Makefile Fri Feb 13 07:51:15 2015 (r278663)
+++ head/usr.bin/chpass/Makefile Fri Feb 13 07:51:26 2015 (r278664)
@@ -9,7 +9,6 @@ PROG= chpass
SRCS= chpass.c edit.c field.c pw_scan.c table.c util.c
BINOWN= root
BINMODE=4555
-PRECIOUSPROG=
.if ${MK_NIS} != "no"
CFLAGS+= -DYP
.endif
@@ -35,4 +34,16 @@ MLINKS= chpass.1 chfn.1 chpass.1 chsh.1
MLINKS+= chpass.1 ypchpass.1 chpass.1 ypchfn.1 chpass.1 ypchsh.1
.endif
+beforeinstall:
+.for i in chpass chfn chsh ypchpass ypchfn ypchsh
+.if exists(${DESTDIR}${BINDIR}/$i)
+ -chflags noschg ${DESTDIR}${BINDIR}/$i
+.endif
+.endfor
+
+.if !defined(NO_FSCHG)
+afterinstall:
+ -chflags schg ${DESTDIR}${BINDIR}/chpass
+.endif
+
.include <bsd.prog.mk>
More information about the svn-src-head
mailing list