Source-Changes-HG archive

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

[src/trunk]: src Provide the correct system Makefile path to the tools make. ...



details:   https://anonhg.NetBSD.org/src/rev/3f148a567d0d
branches:  trunk
changeset: 815102:3f148a567d0d
user:      christos <christos%NetBSD.org@localhost>
date:      Fri Apr 29 16:08:09 2016 +0000

description:
Provide the correct system Makefile path to the tools make. This is needed
because although the arch-specific make wrapper sets $MAKEFLAGS to include
the proper system Makefile path, configure clears $MAKEFLAGS before it invokes
$MAKE to figure out which dependency style to use. This made the build fail
during the gcc build.

diffstat:

 build.sh |  39 +++++++++++++++++++++++----------------
 1 files changed, 23 insertions(+), 16 deletions(-)

diffs (62 lines):

diff -r 5d71da77c985 -r 3f148a567d0d build.sh
--- a/build.sh  Fri Apr 29 13:17:09 2016 +0000
+++ b/build.sh  Fri Apr 29 16:08:09 2016 +0000
@@ -1,5 +1,5 @@
 #! /usr/bin/env sh
-#      $NetBSD: build.sh,v 1.308 2015/06/27 06:00:28 matt Exp $
+#      $NetBSD: build.sh,v 1.309 2016/04/29 16:08:09 christos Exp $
 #
 # Copyright (c) 2001-2011 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -1593,21 +1593,28 @@
        fi
 
        # Build bootstrap ${toolprefix}make if needed.
-       if ${do_rebuildmake}; then
-               statusmsg "Bootstrapping ${toolprefix}make"
-               ${runcmd} cd "${tmpdir}"
-               ${runcmd} env CC="${HOST_CC-cc}" CPPFLAGS="${HOST_CPPFLAGS}" \
-                       CFLAGS="${HOST_CFLAGS--O}" LDFLAGS="${HOST_LDFLAGS}" \
-                       ${HOST_SH} "${TOP}/tools/make/configure" ||
-                   ( cp ${tmpdir}/config.log ${tmpdir}-config.log
-                     bomb "Configure of ${toolprefix}make failed, see ${tmpdir}-config.log for details" )
-               ${runcmd} ${HOST_SH} buildmake.sh ||
-                   bomb "Build of ${toolprefix}make failed"
-               make="${tmpdir}/${toolprefix}make"
-               ${runcmd} cd "${TOP}"
-               ${runcmd} rm -f usr.bin/make/*.o usr.bin/make/lst.lib/*.o
-               done_rebuildmake=true
+       if ! ${do_rebuildmake}; then
+               return
        fi
+
+       statusmsg "Bootstrapping ${toolprefix}make"
+       ${runcmd} cd "${tmpdir}"
+       ${runcmd} env \
+\
+CC="${HOST_CC-cc}" \
+CPPFLAGS="${HOST_CPPFLAGS} -D_PATH_DEFSYSPATH="'\"'${NETBSDSRCDIR}/share/mk'\"' \
+CFLAGS="${HOST_CFLAGS--O}" \
+LDFLAGS="${HOST_LDFLAGS}" \
+\
+           ${HOST_SH} "${TOP}/tools/make/configure" ||
+       ( cp ${tmpdir}/config.log ${tmpdir}-config.log
+             bomb "Configure of ${toolprefix}make failed, see ${tmpdir}-config.log for details" )
+       ${runcmd} ${HOST_SH} buildmake.sh ||
+           bomb "Build of ${toolprefix}make failed"
+       make="${tmpdir}/${toolprefix}make"
+       ${runcmd} cd "${TOP}"
+       ${runcmd} rm -f usr.bin/make/*.o usr.bin/make/lst.lib/*.o
+       done_rebuildmake=true
 }
 
 # validatemakeparams --
@@ -1869,7 +1876,7 @@
        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.308 2015/06/27 06:00:28 matt Exp $
+# Generated from:  \$NetBSD: build.sh,v 1.309 2016/04/29 16:08:09 christos Exp $
 # with these arguments: ${_args}
 #
 



Home | Main Index | Thread Index | Old Index