BSD Make uses `$.CURDIR` instead of `$CURDIR`. BSD and GNU share `$PWD`
though, so it works as a drop in replacement.
Also update scripts in `scripts/` to call `/usr/bin/env` in the shebang,
as BSD places `bash` at `/usr/local/bin/bash` instead of `/bin/bash`