Fix makefile target check with Make jobserver keep-going (#46784)
This commit is contained in:
parent
a8029c8ec4
commit
02a991688f
@ -1855,13 +1855,22 @@ def _has_make_target(self, target):
|
|||||||
#
|
#
|
||||||
# BSD Make:
|
# BSD Make:
|
||||||
# make: don't know how to make test. Stop
|
# make: don't know how to make test. Stop
|
||||||
|
#
|
||||||
|
# Note: "Stop." is not printed when running a Make jobserver (spack env depfile) that runs
|
||||||
|
# with `make -k/--keep-going`
|
||||||
missing_target_msgs = [
|
missing_target_msgs = [
|
||||||
"No rule to make target `{0}'. Stop.",
|
"No rule to make target `{0}'.",
|
||||||
"No rule to make target '{0}'. Stop.",
|
"No rule to make target '{0}'.",
|
||||||
"don't know how to make {0}. Stop",
|
"don't know how to make {0}.",
|
||||||
]
|
]
|
||||||
|
|
||||||
kwargs = {"fail_on_error": False, "output": os.devnull, "error": str}
|
kwargs = {
|
||||||
|
"fail_on_error": False,
|
||||||
|
"output": os.devnull,
|
||||||
|
"error": str,
|
||||||
|
# Remove MAKEFLAGS to avoid inherited flags from Make jobserver (spack env depfile)
|
||||||
|
"extra_env": {"MAKEFLAGS": ""},
|
||||||
|
}
|
||||||
|
|
||||||
stderr = make("-n", target, **kwargs)
|
stderr = make("-n", target, **kwargs)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user