Created
May 14, 2013 20:03
-
-
Save raine/5579022 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ cat Makefile | |
| .PHONY: all clean | |
| all: check-env | |
| echo $(ENV) | |
| clean: | |
| echo "clean" | |
| check-env: | |
| ifndef ENV | |
| $(error ENV is undefined) | |
| endif | |
| $ make clean | |
| Makefile:11: *** ENV is undefined. Stop. | |
| $ make clean ENV=foo | |
| echo "clean" | |
| clean | |
| $ make | |
| Makefile:11: *** ENV is undefined. Stop. | |
| $ make ENV=foo | |
| echo foo | |
| foo |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment