Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 8 Mar 2019 15:48:19 +0000 (UTC)
From:      Enji Cooper <ngie@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org
Subject:   svn commit: r344923 - stable/12/share/mk
Message-ID:  <201903081548.x28FmJ8Z057679@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ngie
Date: Fri Mar  8 15:48:19 2019
New Revision: 344923
URL: https://svnweb.freebsd.org/changeset/base/344923

Log:
  MFC r343845:
  
  Clean up all directories created by `make hier`
  
  The logic I introduced in r322511 unfortunately left chflags schg'ed
  directories behind created by `make hier` (in the stock /etc/mtree
  files, this is limited to /var/empty).
  
  The proposed change calls `chflags -R 0` and `rm -Rf ...` to clean all
  of the directories that could not be removed by `${MAKE} clean`.
  `${MAKE} clean` in bsd.obj.mk calls `cleandir`/`cleanobj`, which handles
  the first directory tree walk/removal.
  
  Approved by:	emaste (mentor)
  Differential Revision: https://reviews.freebsd.org/D19174

Modified:
  stable/12/share/mk/suite.test.mk
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/share/mk/suite.test.mk
==============================================================================
--- stable/12/share/mk/suite.test.mk	Fri Mar  8 10:03:16 2019	(r344922)
+++ stable/12/share/mk/suite.test.mk	Fri Mar  8 15:48:19 2019	(r344923)
@@ -120,5 +120,7 @@ beforecheck:
 #       etc.
 aftercheck:
 	@cd ${.CURDIR} && ${MAKE} clean
+	@chflags -R 0 "${DESTDIR}"
+	@rm -Rf "${DESTDIR}"
 
 .endif



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201903081548.x28FmJ8Z057679>