treat root packages consistently with deps

This is an alternative to fix the bug reported in #22.

We avoid duplicate packages according to the repo root.
This also needs to happen for packages in the root set,
otherwise a repo with no go files in its root (for
example a package foo for which 'go list foo/...' doesn't
include foo itself) can have its internal dependencies
wrongly treated as external dependencies.