Module Name:    src
Committed By:   apb
Date:           Sun Aug  3 09:22:29 UTC 2014

Modified Files:
        src: build.sh

Log Message:
BUILDINFO part 4: build.sh

Add BUILDINFO to the list of variables saved in the makewrapper script,
and print any non-blank BUILDINFO lines near the beginning of the output
from build.sh.
Index: build.sh
===================================================================
RCS file: /cvsroot/src/build.sh,v
retrieving revision 1.286
diff -d -p -u -r1.286 build.sh
--- build.sh    3 Aug 2014 01:03:41 -0000       1.286
+++ build.sh    3 Aug 2014 09:20:46 -0000
@@ -1299,6 +1299,7 @@ parseoptions()
        #
        makeenv="${makeenv} TOOLDIR MACHINE MACHINE_ARCH MAKEFLAGS"
        [ -z "${BUILDID}" ] || makeenv="${makeenv} BUILDID"
+       [ -z "${BUILDINFO}" ] || makeenv="${makeenv} BUILDINFO"
        MAKEFLAGS="-de -m ${TOP}/share/mk ${MAKEFLAGS}"
        MAKEFLAGS="${MAKEFLAGS} MKOBJDIRS=${MKOBJDIRS-yes}"
        export MAKEFLAGS MACHINE MACHINE_ARCH
@@ -2078,6 +2079,13 @@ main()
        if [ -n "${BUILDID}" ]; then
                statusmsg2 "BUILDID:"  "${BUILDID}"
        fi
+       if [ -n "${BUILDINFO}" ]; then
+               printf "%b\n" "${BUILDINFO}" | \
+               while read -r line ; do
+                       [ -s "${line}" ] && continue
+                       statusmsg2 "BUILDINFO:"  "${line}"
+               done
+       fi

        rebuildmake
        validatemakeparams


To generate a diff of this commit:
cvs rdiff -u -r1.286 -r1.287 src/build.sh

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/build.sh
diff -u src/build.sh:1.286 src/build.sh:1.287
--- src/build.sh:1.286	Sun Aug  3 01:03:41 2014
+++ src/build.sh	Sun Aug  3 09:22:29 2014
@@ -1,5 +1,5 @@
 #! /usr/bin/env sh
-#	$NetBSD: build.sh,v 1.286 2014/08/03 01:03:41 riz Exp $
+#	$NetBSD: build.sh,v 1.287 2014/08/03 09:22:29 apb Exp $
 #
 # Copyright (c) 2001-2011 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -1299,6 +1299,7 @@ parseoptions()
 	#
 	makeenv="${makeenv} TOOLDIR MACHINE MACHINE_ARCH MAKEFLAGS"
 	[ -z "${BUILDID}" ] || makeenv="${makeenv} BUILDID"
+	[ -z "${BUILDINFO}" ] || makeenv="${makeenv} BUILDINFO"
 	MAKEFLAGS="-de -m ${TOP}/share/mk ${MAKEFLAGS}"
 	MAKEFLAGS="${MAKEFLAGS} MKOBJDIRS=${MKOBJDIRS-yes}"
 	export MAKEFLAGS MACHINE MACHINE_ARCH
@@ -1774,7 +1775,7 @@ createmakewrapper()
 	eval cat <<EOF ${makewrapout}
 #! ${HOST_SH}
 # Set proper variables to allow easy "make" building of a NetBSD subtree.
-# Generated from:  \$NetBSD: build.sh,v 1.286 2014/08/03 01:03:41 riz Exp $
+# Generated from:  \$NetBSD: build.sh,v 1.287 2014/08/03 09:22:29 apb Exp $
 # with these arguments: ${_args}
 #
 
@@ -2078,6 +2079,13 @@ main()
 	if [ -n "${BUILDID}" ]; then
 		statusmsg2 "BUILDID:"  "${BUILDID}"
 	fi
+	if [ -n "${BUILDINFO}" ]; then
+		printf "%b\n" "${BUILDINFO}" | \
+		while read -r line ; do
+			[ -s "${line}" ] && continue
+			statusmsg2 "BUILDINFO:"  "${line}"
+		done
+	fi
 
 	rebuildmake
 	validatemakeparams

Reply via email to