HomeFreeBSD

Makefile: Fix MAKEOBJDIRPREFIX command-line variable check for bmake

Description

Makefile: Fix MAKEOBJDIRPREFIX command-line variable check for bmake

Unlike the old fmake, running make FOO=bar when using bmake doesn't put
FOO=bar in .MAKEFLAGS at the top level, it instead just puts FOO in
.MAKEOVERRIDES and the full MAKEFLAGS will be formed for sub-makes.
Moreover, this only applies for sub-makes in rules, so this doesn't
apply to those in shell assignments. This means that the current check
does not catch make MAKEOBJDIRPREFIX=..., only those defined in config
files. Thus we must also check .MAKEOVERRIDES explicitly.

Reviewed by: sjg
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D31015

(cherry picked from commit d0c737e18454868447f731fe2b10d04f50d9d53b)

Details

Provenance
jrtc27Authored on Jul 21 2021, 1:48 AM
Reviewer
sjg
Differential Revision
D31015: Makefile: Fix MAKEOBJDIRPREFIX command-line variable check for bmake
Parents
rG3ac63c72714c: riscv: Fix pindex level confusion
Branches
Unknown
Tags
Unknown