Clean up and consolidate buildModule

Removes calls to error (use IOError instead) and remove the
Util.Environment module (fold it in to Testing).
Add (and document) environment variable overrides for finding clang and opt

This change makes the buildModule helper more flexible