Closed rushmorem closed 7 years ago
Thx for reporting this.
I plan to write tests for go2nix
with few packages (i will look at coredns too) as a examples to address https://github.com/kamilchm/go2nix/issues/21.
I'll come back to this next week.
I found the problem with coredns
- unused imports in https://github.com/miekg/coredns/blob/master/core/coredns.go
go get
and go build
won't go as deep as go2nix
into these dependencies but I don't know where is the right place to stop going deeper :/
Go package management in it's glory :(
Got it, go2nix
doesn't look for packages provided in vendor
of dependent packages, eg. k8s.io/kubernetes/vendor
in this case.
I need to implement test cases from https://www.youtube.com/watch?v=6gdVhHMxNTo and then do it right.
Sometimes
go2nix
requires additional packages beyond those required bygo build
to actually build. For example, if you are packaging coredns, ago get -d ./
is sufficient to fetch all its dependancies for building their main package. However, runninggo2nix save
requires some other packages before it can successfully compile theNix
expressions.I ran into this a number of times while packaging for
Nix
, I ended up creating a script that downloads these extra requirements whilego2nix save
ing:-