NetBSD-Users archive

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

Re: postinstall bug in mtree check?



On Wed, Sep 24, 2014 at 03:41:49PM -0500, J. Lewis Muir wrote:
> Hello, NetBSD Users.
> 
> I just built on and for amd64 from the netbsd-6 CVS branch source
> and installed and ran a postinstall check of the mtree item and
> got an unexpected difference.  The output is below.  Looking at
> the postinstall source, I'm thinking (but haven't confirmed) the
> problem is that make is echoing to stdout the command executed for the
> emit_dist_file target, and that is getting erroneously captured when
> postinstall invokes it and redirects stdout to create the expected
> NetBSD.dist mtree file thus causing the expected and actual files to
> differ.

Adding '-s' to the make invocation in postinstall fixes the problem.
Below is a patch against the netbsd-6 CVS branch.

Thanks,

Lewis

Index: usr.sbin/postinstall/postinstall
===================================================================
RCS file: /cvsroot/src/usr.sbin/postinstall/postinstall,v
retrieving revision 1.129.2.11
diff -u -r1.129.2.11 postinstall
--- usr.sbin/postinstall/postinstall	21 May 2014 20:29:02 -0000	1.129.2.11
+++ usr.sbin/postinstall/postinstall	24 Sep 2014 20:57:20 -0000
@@ -998,7 +998,7 @@
 	if ! $SOURCEMODE; then
 		MTREE_DIR="${SRC_DIR}/etc/mtree"
 	else
-		${MAKE} -C ${SRC_DIR}/etc/mtree emit_dist_file > \
+		${MAKE} -s -C ${SRC_DIR}/etc/mtree emit_dist_file > \
 		    "${SCRATCHDIR}/NetBSD.dist"
 		MTREE_DIR="${SCRATCHDIR}"
 	fi


Home | Main Index | Thread Index | Old Index