Since an undefined variable can lead to an unexpected behavior if it is simply replaced with empty text (consider target directories), is there a way to have make check if a variable is undefined and stop with an error in that case?
The condition can be detected with conditionals but then how to stop execution?
ifeq ($(strip $(notdefinedforsure_man)),)
out = Undefined variable detected
endif
I'm looking for something like requiredef var1, var2
or a simple return with error statement to be used in the conditional above