Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 22 Feb 2017 20:35:50 +0000 (UTC)
From:      Bryan Drewery <bdrewery@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r434639 - in head/ports-mgmt/poudriere-devel: . files
Message-ID:  <201702222035.v1MKZoDP060498@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bdrewery
Date: Wed Feb 22 20:35:50 2017
New Revision: 434639
URL: https://svnweb.freebsd.org/changeset/ports/434639

Log:
  Restore 'umount -f' usage for now as older releases do not support 'umount -n'.
  
  A better fix will be coming soon.
  
  Reported by:	ohauer

Modified:
  head/ports-mgmt/poudriere-devel/Makefile
  head/ports-mgmt/poudriere-devel/files/patch-src__libexec__poudriere__cached__cached.c
  head/ports-mgmt/poudriere-devel/files/patch-src_share_poudriere_common.sh
  head/ports-mgmt/poudriere-devel/files/patch-src_share_poudriere_include_fs.sh

Modified: head/ports-mgmt/poudriere-devel/Makefile
==============================================================================
--- head/ports-mgmt/poudriere-devel/Makefile	Wed Feb 22 20:30:47 2017	(r434638)
+++ head/ports-mgmt/poudriere-devel/Makefile	Wed Feb 22 20:35:50 2017	(r434639)
@@ -2,7 +2,7 @@
 
 PORTNAME=	poudriere
 DISTVERSION=	3.1.99.20170221
-PORTREVISION=	0
+PORTREVISION=	1
 CATEGORIES=	ports-mgmt
 MASTER_SITES=	LOCAL/bdrewery/${PORTNAME}/ \
 		http://mirror.shatow.net/freebsd/${PORTNAME}/ \
@@ -21,8 +21,6 @@ GH_ACCOUNT=	freebsd
 GH_TAGNAME=	3.0-1822-ge8f0d3e
 #DISTNAME=	${GH_ACCOUNT}-${GH_PROJECT}-${GH_TAGNAME}
 
-BROKEN=	umount -n not supported before 11, working on a fix
-
 GNU_CONFIGURE=	yes
 ETCDIR=		${PREFIX}/etc/poudriere.d
 

Modified: head/ports-mgmt/poudriere-devel/files/patch-src__libexec__poudriere__cached__cached.c
==============================================================================
--- head/ports-mgmt/poudriere-devel/files/patch-src__libexec__poudriere__cached__cached.c	Wed Feb 22 20:30:47 2017	(r434638)
+++ head/ports-mgmt/poudriere-devel/files/patch-src__libexec__poudriere__cached__cached.c	Wed Feb 22 20:35:50 2017	(r434639)
@@ -1,6 +1,4 @@
-diff --git src/libexec/poudriere/cached/cached.c src/libexec/poudriere/cached/cached.c
-index 68ba6e6..ce266cd 100644
---- src/libexec/poudriere/cached/cached.c
+--- src/libexec/poudriere/cached/cached.c.orig	2017-02-20 23:37:27 UTC
 +++ src/libexec/poudriere/cached/cached.c
 @@ -26,6 +26,7 @@
  

Modified: head/ports-mgmt/poudriere-devel/files/patch-src_share_poudriere_common.sh
==============================================================================
--- head/ports-mgmt/poudriere-devel/files/patch-src_share_poudriere_common.sh	Wed Feb 22 20:30:47 2017	(r434638)
+++ head/ports-mgmt/poudriere-devel/files/patch-src_share_poudriere_common.sh	Wed Feb 22 20:35:50 2017	(r434639)
@@ -1,11 +1,35 @@
---- src/share/poudriere/common.sh.orig	2015-11-30 17:26:13 UTC
+--- src/share/poudriere/common.sh.orig	2017-02-22 20:34:08 UTC
 +++ src/share/poudriere/common.sh
-@@ -1856,7 +1856,7 @@ jail_stop() {
- 	fi
- 	msg "Umounting file systems"
- 	destroyfs ${MASTERMNT} jail || :
--	rm -rfx ${MASTERMNT}/../
-+	rm -rf ${MASTERMNT}/../
- 	export STATUS=0
+@@ -3216,7 +3216,7 @@ build_pkg() {
+ 
+ 	if [ ${TMPFS_LOCALBASE} -eq 1 -o ${TMPFS_ALL} -eq 1 ]; then
+ 		if [ -f "${mnt}/${LOCALBASE:-/usr/local}/.mounted" ]; then
+-			umount -n ${mnt}/${LOCALBASE:-/usr/local}
++			umount -f ${mnt}/${LOCALBASE:-/usr/local}
+ 		fi
+ 		mnt_tmpfs localbase ${mnt}/${LOCALBASE:-/usr/local}
+ 		do_clone "${MASTERMNT}/${LOCALBASE:-/usr/local}" \
+@@ -3322,7 +3322,7 @@ stop_build() {
+ 		_my_path mnt
+ 
+ 		if [ -f "${mnt}/.npkg_mounted" ]; then
+-			umount -n "${mnt}/.npkg"
++			umount -f "${mnt}/.npkg"
+ 			rm -f "${mnt}/.npkg_mounted"
+ 		fi
+ 		rm -rf "${PACKAGES}/.npkg/${PKGNAME}"
+@@ -4693,12 +4693,12 @@ clean_restricted() {
+ 	bset status "clean_restricted:"
+ 	# Remount rw
+ 	# mount_nullfs does not support mount -u
+-	umount -n ${MASTERMNT}/packages
++	umount -f ${MASTERMNT}/packages
+ 	mount_packages
+ 	injail /usr/bin/make -s -C /usr/ports -j ${PARALLEL_JOBS} \
+ 	    RM="/bin/rm -fv" ECHO_MSG="true" clean-restricted
+ 	# Remount ro
+-	umount -n ${MASTERMNT}/packages
++	umount -f ${MASTERMNT}/packages
+ 	mount_packages -o ro
+ }
  
- 	# Don't override if there is a failure to grab the last status.

Modified: head/ports-mgmt/poudriere-devel/files/patch-src_share_poudriere_include_fs.sh
==============================================================================
--- head/ports-mgmt/poudriere-devel/files/patch-src_share_poudriere_include_fs.sh	Wed Feb 22 20:30:47 2017	(r434638)
+++ head/ports-mgmt/poudriere-devel/files/patch-src_share_poudriere_include_fs.sh	Wed Feb 22 20:35:50 2017	(r434639)
@@ -1,15 +1,20 @@
---- src/share/poudriere/include/fs.sh.orig	2016-05-18 22:58:28 UTC
+--- src/share/poudriere/include/fs.sh.orig	2017-02-22 20:34:08 UTC
 +++ src/share/poudriere/include/fs.sh
-@@ -191,10 +191,10 @@ destroyfs() {
- 		zfs destroy -rf ${fs}
- 		rmdir ${mnt}
- 	else
--		rm -rfx ${mnt} 2>/dev/null || :
-+		rm -rf ${mnt} 2>/dev/null || :
+@@ -98,7 +98,7 @@ umountfs() {
+ 
+ 	[ -d "${mnt}" ] || return 0
+ 	mnt=$(realpath ${mnt})
+-	if ! findmounts "${mnt}" "${pattern}" | xargs umount -n; then
++	if ! findmounts "${mnt}" "${pattern}" | xargs umount -f; then
+ 		findmounts "${mnt}" "${pattern}" | xargs umount -fv || :
+ 	fi
+ 
+@@ -198,7 +198,7 @@ destroyfs() {
+ 	umountfs ${mnt} 1
+ 	if [ ${TMPFS_ALL} -eq 1 ]; then
  		if [ -d "${mnt}" ]; then
- 			chflags -R 0 ${mnt}
--			rm -rfx ${mnt}
-+			rm -rf ${mnt}
+-			if ! umount -n "${mnt}" 2>/dev/null; then
++			if ! umount -f "${mnt}" 2>/dev/null; then
+ 				umount -f "${mnt}" 2>/dev/null || :
+ 			fi
  		fi
- 	fi
- }



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