Correctly handle undefined GOPATH/GOROOT

Closes #49.