pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/mk Introduce PRIVILEGED_STAGE.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/1462311dffbe
branches:  trunk
changeset: 530522:1462311dffbe
user:      adrianp <adrianp%pkgsrc.org@localhost>
date:      Sun Jul 01 00:06:40 2007 +0000

description:
Introduce PRIVILEGED_STAGE.

This can currently only be set to 'clean' which will result in a
priveleged 'make clean' operation in case any package builds result
in files under ${WRKSRC} that are owned by root.

This is useful for certain packages e.g. python (on NetBSD) and ezm3
and possibly more.

diffstat:

 mk/bsd.pkg.clean.mk |  6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diffs (20 lines):

diff -r 5ada8d153961 -r 1462311dffbe mk/bsd.pkg.clean.mk
--- a/mk/bsd.pkg.clean.mk       Sat Jun 30 19:45:13 2007 +0000
+++ b/mk/bsd.pkg.clean.mk       Sun Jul 01 00:06:40 2007 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.clean.mk,v 1.9 2006/10/09 11:44:06 joerg Exp $
+# $NetBSD: bsd.pkg.clean.mk,v 1.10 2007/07/01 00:06:40 adrianp Exp $
 #
 # This Makefile fragment is included to bsd.pkg.mk and defines the
 # relevant variables and targets for the "clean" phase.
@@ -27,6 +27,10 @@
 
 CLEANDEPENDS?= no
 
+.if defined(PRIVILEGED_STAGE) && !empty(PRIVILEGED_STAGE:Mclean)
+_MAKE_CLEAN_AS_ROOT=yes
+.endif
+
 .PHONY: clean-depends
 clean-depends:
        ${_PKG_SILENT}${_PKG_DEBUG}                                     \



Home | Main Index | Thread Index | Old Index