Update to new GoPackage API.

It turned out figuring out if a Go package is under vcs was quite slow
(for lots of packages), so it should only be done when necessary.