Source-Changes-HG archive

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

[src/netbsd-10]: src/tools Pull up following revision(s) (requested by lukem ...



details:   https://anonhg.NetBSD.org/src/rev/6d99cec5860b
branches:  netbsd-10
changeset: 376043:6d99cec5860b
user:      martin <martin%NetBSD.org@localhost>
date:      Sun May 28 09:49:03 2023 +0000

description:
Pull up following revision(s) (requested by lukem in ticket #177):

        tools/Makefile.gnuhost: revision 1.56
        external/gpl3/gcc/usr.bin/host-libcpp/Makefile: revision 1.6

Fix passing -j NNN to gmake

Use a more restrictive pattern to extract -j NNN from MAKEFLAGS
into GMAKE_J_ARGS, to avoid false positives when the source directory
has "-j" in the path (e.g "amd64-job-000012" or "src-j9999").

Previously this could pass either -"-j" or "-j BIGNUM" to gmake
and result in "vfork: Resource temporarily unavailable" failures.

PR misc/54456

diffstat:

 external/gpl3/gcc/usr.bin/host-libcpp/Makefile |  4 ++--
 tools/Makefile.gnuhost                         |  4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diffs (36 lines):

diff -r 19bd6fc3277d -r 6d99cec5860b external/gpl3/gcc/usr.bin/host-libcpp/Makefile
--- a/external/gpl3/gcc/usr.bin/host-libcpp/Makefile    Sun May 28 09:47:27 2023 +0000
+++ b/external/gpl3/gcc/usr.bin/host-libcpp/Makefile    Sun May 28 09:49:03 2023 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.5 2020/06/24 05:06:08 rin Exp $
+#      $NetBSD: Makefile,v 1.5.6.1 2023/05/28 09:49:03 martin Exp $
 
 BUILD_ENV= \
                AR=${HOST_AR:Q} \
@@ -19,7 +19,7 @@ BUILD_ENV= \
                RANLIB=${HOST_RANLIB:Q} \
                YACC=${YACC:Q}
 
-GMAKE_J_ARGS?= ${MAKEFLAGS:[*]:M*-j*:C/.*(-j ?[0-9]*).*/\1/W}
+GMAKE_J_ARGS?= ${MAKEFLAGS:[*]:M*-j*:C/(^|.* )(-j ?[0-9][0-9]*).*/\2/W}
 BUILD_COMMAND= /usr/bin/env -i ${BUILD_ENV} ${TOOL_GMAKE} ${GMAKE_J_ARGS} -e
 
 libcpp/libcpp.a:
diff -r 19bd6fc3277d -r 6d99cec5860b tools/Makefile.gnuhost
--- a/tools/Makefile.gnuhost    Sun May 28 09:47:27 2023 +0000
+++ b/tools/Makefile.gnuhost    Sun May 28 09:49:03 2023 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile.gnuhost,v 1.54 2021/08/29 08:36:00 rillig Exp $
+#      $NetBSD: Makefile.gnuhost,v 1.54.2.1 2023/05/28 09:49:03 martin Exp $
 #
 # Rules used when building a GNU host package.  Expects MODULE to be set.
 #
@@ -100,7 +100,7 @@ BUILD_COMMAND=      ${BUILD_ENV} ${MAKE} ${MA
 # gmake version of this puts MAKE_ARGS in the environment to be sure that
 # sub-gmake's get them, otherwise tools/gcc tries to build libgcc and
 # fails.  it also uses "env -i" to entirely clear out MAKEFLAGS.
-GMAKE_J_ARGS?= ${MAKEFLAGS:[*]:M*-j*:C/.*(-j ?[0-9]*).*/\1/W}
+GMAKE_J_ARGS?= ${MAKEFLAGS:[*]:M*-j*:C/(^|.* )(-j ?[0-9][0-9]*).*/\2/W}
 BUILD_COMMAND= /usr/bin/env -i ${BUILD_ENV} ${MAKE_ARGS:N-*} ${TOOL_GMAKE} ${GMAKE_J_ARGS} -e ${MAKE_ARGS}
 
 .endif



Home | Main Index | Thread Index | Old Index