summaryrefslogtreecommitdiff
path: root/Tools/portbuild
diff options
context:
space:
mode:
authorSatoshi Asami <asami@FreeBSD.org>1999-09-22 00:58:26 +0000
committerSatoshi Asami <asami@FreeBSD.org>1999-09-22 00:58:26 +0000
commit1ef91d42b2ce8b28e73cc9f4ea1a71bf1e21b8cc (patch)
treebf2c45ef407ad76325c2d2528efadff3a6f0f716 /Tools/portbuild
parentRun Xvfb if it exists and set DISPLAY accordingly. This helps ports (diff)
Run chflags if rm -rf of chroot dir fails -- some port may have
left some schg junk around.
Notes
Notes: svn path=/head/; revision=21869
Diffstat (limited to 'Tools/portbuild')
-rwxr-xr-xTools/portbuild/scripts/setupnode7
1 files changed, 6 insertions, 1 deletions
diff --git a/Tools/portbuild/scripts/setupnode b/Tools/portbuild/scripts/setupnode
index d41a8422bcfd..ff876b6f2f80 100755
--- a/Tools/portbuild/scripts/setupnode
+++ b/Tools/portbuild/scripts/setupnode
@@ -6,7 +6,12 @@ fi
if [ $(echo $(/sbin/mount | grep "$2/.*(read-only)" | awk '{print $3}' | wc -c)) != 0 ]; then
/sbin/umount -f $(/sbin/mount | grep "$2/.*(read-only)" | awk '{print $3}')
fi
-rm -rf $2/*/chroot/*
+
+if ! rm -rf $2/*/chroot/* >/dev/null 2>&1; then
+ chflags -R noschg $2/*/chroot/*
+ rm -rf $2/*/chroot/*
+fi
+
scp -p -a $1:$2/scripts/portbuild $2/scripts
md5=$(/sbin/md5 $2/$3/tarballs/bindist.tar | awk '{print $4}')
if [ "$md5" = "$4" ]; then