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`
These two tools are used in the "cov" Makefile target, but installing
these were not automated. This PR removes the ambiguity where a
developer tries to do a `make cov` and finds that the tools are not
installed.