Source-Changes-HG archive

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

[src/trunk]: src/distrib/sets Remove the code that used "${MTREE} -C ..." to ...



details:   https://anonhg.NetBSD.org/src/rev/569dbba81f68
branches:  trunk
changeset: 586868:569dbba81f68
user:      apb <apb%NetBSD.org@localhost>
date:      Wed Jan 04 15:03:39 2006 +0000

description:
Remove the code that used "${MTREE} -C ..." to sanitise the plist.  We
can now assume that it's already been sanitised before maketars was
invoked.

Reviewed by agc

diffstat:

 distrib/sets/maketars |  19 ++++---------------
 1 files changed, 4 insertions(+), 15 deletions(-)

diffs (44 lines):

diff -r bb5e1dbc11f7 -r 569dbba81f68 distrib/sets/maketars
--- a/distrib/sets/maketars     Wed Jan 04 14:58:58 2006 +0000
+++ b/distrib/sets/maketars     Wed Jan 04 15:03:39 2006 +0000
@@ -1,6 +1,6 @@
 #!/bin/sh
 #
-# $NetBSD: maketars,v 1.58 2006/01/03 18:31:09 apb Exp $
+# $NetBSD: maketars,v 1.59 2006/01/04 15:03:39 apb Exp $
 #
 # Make release tar files for some or all lists.  Usage:
 # maketars [-b] [-x] [-i installdir] [-a arch] [-m machine] [-s setsdir]
@@ -126,18 +126,6 @@
 # build the setfiles
 #
 
-if [ -n "${metalog}" ]; then
-       (
-               cat "${etcdir}/mtree/NetBSD.dist"
-               echo "/unset all"
-               cat "${metalog}" 2>/dev/null
-       ) | ${MTREE} -C -k all -N "${etcdir}" > "${SDIR}/metalog"
-       rv=$?
-       if [ ${rv} -ne 0 ]; then
-               echo 1>&2 "${prog}: mtree parse of ${metalog} failed"
-               exit ${rv}
-       fi
-fi
 for setname in ${lists}; do
        ${HOST_SH} "${setsdir}/makeflist" -a "${MACHINE_ARCH}" -m "${MACHINE}" \
            -s "${setsdir}" "${setname}" > "${SDIR}/flist.${setname}"
@@ -148,10 +136,11 @@
                (
                        echo "/set uname=root gname=wheel"
                        ${AWK} -f "${rundir}/join.awk" \
-                               "${SDIR}/flist.${setname}.full" \
-                               "${SDIR}/metalog"
+                               "${SDIR}/flist.${setname}.full" "${metalog}"
                        echo "./etc/mtree/set.${setname} type=file mode=0444"
                ) > "${setlistdir}/set.${setname}"
+               # We deliberately do not add set.${setname} to ${metalog},
+               # because we depend on it as an input.
        elif ! cmp -s "${SDIR}/flist.${setname}" \
                        "${setlistdir}/set.${setname}" >/dev/null 2>&1; then
                rm -f "${setlistdir}/set.${setname}"



Home | Main Index | Thread Index | Old Index