diff options
author | Simon J. Gerraty <sjg@FreeBSD.org> | 2022-07-27 15:58:09 +0000 |
---|---|---|
committer | Simon J. Gerraty <sjg@FreeBSD.org> | 2022-07-27 16:00:30 +0000 |
commit | 532d4fbfa0829be624bd1eea0e264b42d7dbea75 (patch) | |
tree | 51f4aa21e721d3a0b17978e50a8ccdb3b8972c2c /contrib/bmake | |
parent | da10709dede19c04ae89518fd3630cd4f90e06dc (diff) | |
parent | 31a96ca5f0b6e5f8f7fa8cecf3a5c4354b3b096f (diff) | |
download | src-532d4fbfa0829be624bd1eea0e264b42d7dbea75.tar.gz src-532d4fbfa0829be624bd1eea0e264b42d7dbea75.zip |
Update to bmake-20220726
Merge commit '31a96ca5f0b6e5f8f7fa8cecf3a5c4354b3b096f'
Diffstat (limited to 'contrib/bmake')
-rw-r--r-- | contrib/bmake/ChangeLog | 6 | ||||
-rw-r--r-- | contrib/bmake/Makefile | 21 | ||||
-rw-r--r-- | contrib/bmake/VERSION | 2 | ||||
-rw-r--r-- | contrib/bmake/unit-tests/Makefile | 3 |
4 files changed, 28 insertions, 4 deletions
diff --git a/contrib/bmake/ChangeLog b/contrib/bmake/ChangeLog index b9b5711e6e09..0762e4e6b925 100644 --- a/contrib/bmake/ChangeLog +++ b/contrib/bmake/ChangeLog @@ -1,3 +1,9 @@ +2022-07-26 Simon J Gerraty <sjg@beast.crufty.net> + + * VERSION (_MAKE_VERSION): 20220726 + + * Auto-create objdir for bmake/unit-tests if appropriate + 2022-07-24 Simon J Gerraty <sjg@beast.crufty.net> * VERSION (_MAKE_VERSION): 20220724 diff --git a/contrib/bmake/Makefile b/contrib/bmake/Makefile index 82d9db52af76..201e4869dc3f 100644 --- a/contrib/bmake/Makefile +++ b/contrib/bmake/Makefile @@ -1,4 +1,4 @@ -# $Id: Makefile,v 1.117 2021/12/04 18:51:30 sjg Exp $ +# $Id: Makefile,v 1.120 2022/07/26 23:02:54 sjg Exp $ PROG= bmake @@ -215,7 +215,24 @@ install-mk: # A simple unit-test driver to help catch regressions TEST_MAKE ?= ${.OBJDIR}/${PROG:T} -accept test: +accept test: .NOMETA cd ${.CURDIR}/unit-tests && \ MAKEFLAGS= ${TEST_MAKE} -r -m / ${.TARGET} ${TESTS:DTESTS=${TESTS:Q}} + +.if make(test) && ${MK_AUTO_OBJ} == "yes" +# The test target above visits unit-tests with -r -m / +# which prevents MK_AUTO_OBJ doing its job +# so do it here +.if defined(MAKEOBJDIRPREFIX) || ${MAKEOBJDIR:U:M*/*} != "" +_utobj = ${.OBJDIR}/unit-tests +.else +_utobj = ${.CURDIR}/unit-tests/${MAKEOBJDIR:Uobj} +.endif +utobj: .NOMETA + @test -d ${_utobj} && exit 0; \ + echo "[Creating ${_utobj}...]"; \ + umask ${OBJDIR_UMASK:U002}; \ + mkdir -p ${_utobj} +test: utobj +.endif diff --git a/contrib/bmake/VERSION b/contrib/bmake/VERSION index 34b791ec9d8f..bbf893546603 100644 --- a/contrib/bmake/VERSION +++ b/contrib/bmake/VERSION @@ -1,2 +1,2 @@ # keep this compatible with sh and make -_MAKE_VERSION=20220724 +_MAKE_VERSION=20220726 diff --git a/contrib/bmake/unit-tests/Makefile b/contrib/bmake/unit-tests/Makefile index de9720131535..10d8f32c61c7 100644 --- a/contrib/bmake/unit-tests/Makefile +++ b/contrib/bmake/unit-tests/Makefile @@ -1,4 +1,4 @@ -# $Id: Makefile,v 1.181 2022/06/13 00:18:20 sjg Exp $ +# $Id: Makefile,v 1.182 2022/07/26 19:39:32 sjg Exp $ # # $NetBSD: Makefile,v 1.318 2022/06/10 21:28:50 rillig Exp $ # @@ -501,6 +501,7 @@ ENV.depsrc-optional+= TZ=UTC ENV.deptgt-phony+= MAKESYSPATH=. ENV.directive-undef= ENV_VAR=env-value ENV.envfirst= FROM_ENV=value-from-env +ENV.opt-m-include-dir= ${MAKEOBJDIR:DMAKEOBJDIR=${MAKEOBJDIR}} ENV.varmisc= FROM_ENV=env ENV.varmisc+= FROM_ENV_BEFORE=env ENV.varmisc+= FROM_ENV_AFTER=env |