Note that GOPATH needs to be set when building packer

This will explain the error that you receive when you go to build packer for the first time.