summaryrefslogtreecommitdiff
path: root/distrib/sets/maketars
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2006-12-09 21:12:55 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2006-12-09 21:12:55 +0000
commitba86737df47094b68484363f9f96912da9f676e5 (patch)
treed1ec47679985d267bf918dbe044daf8b15a78a51 /distrib/sets/maketars
parent13e968d0c3b7210b933472ce85de8917ee590d74 (diff)
sort the sets to make sure that shared libraries are early in the sets, to
avoid various "interrupt while upgrading and you are hosed" problems. prodded by drahn, this will save kitella from doing 6 hour drives, ok espie
Diffstat (limited to 'distrib/sets/maketars')
-rw-r--r--distrib/sets/maketars14
1 files changed, 11 insertions, 3 deletions
diff --git a/distrib/sets/maketars b/distrib/sets/maketars
index 5e79ed09af3..bacf3a06b58 100644
--- a/distrib/sets/maketars
+++ b/distrib/sets/maketars
@@ -1,5 +1,5 @@
#!/bin/sh
-# $OpenBSD: maketars,v 1.18 2006/07/13 02:19:28 nick Exp $
+# $OpenBSD: maketars,v 1.19 2006/12/09 21:12:54 deraadt Exp $
#
# Copyright (c) 2001 Theo de Raadt
# All rights reserved.
@@ -47,11 +47,19 @@ lists=`pwd`/lists
tardir=$RELEASEDIR
fsdir=$DESTDIR
+TMP=`mktemp /tmp/_maketars.XXXXXXXXXX` || exit 1
+TMP2=`mktemp /tmp/_maketars2.XXXXXXXXXX` || exit 1
+trap 'rm -f $TMP $TMP2; exit 1' 1 15
+
cd $fsdir
for i in base comp etc game man misc; do
echo -n "$i: "
- cat ${lists}/$i/mi ${lists}/$i/md.${arch} | sort | \
- pax -w -d | gzip > ${tardir}/$i${RELEASE}.tgz
+ sort ${lists}/$i/mi ${lists}/$i/md.${arch} > $TMP
+ cat $TMP | grep '^./usr/lib/lib' > $TMP2
+ cat $TMP | grep -v '^./usr/lib/lib' >> $TMP2
+ cat $TMP2 | pax -w -d | gzip > ${tardir}/$i${RELEASE}.tgz
echo "done."
done
+rm -f $TMP $TMP2
+exit 0