This will cause a fatal error if ENV is undefined and something needs it (in GNUMake, anyway).
.PHONY: deploy check-env deploy: check-env ... other-thing-that-needs-env: check-env ... check-env: ifndef ENV $(error ENV is undefined) endif
(Note that ifndef and endif are not indented – they control what make “sees”, taking effect before the Makefile is run. “$(error” is indented with a tab so that it only runs in the context of the rule.)