I've created a sample project to demonstrate this issue. The project has a Gopkg.toml file that clearly states not to prune "non-go" files for the specified package yet after the dep ensure some C files are missing thus go build does not work: https://github.com/tapir/dep-prune-test
To reproduce
go get -d github.com/tapir/dep-prune-test
cd $GOPATH/src/github.com/tapir/dep-prune-test
dep ensure
go build
dep are you using (dep version)?0.4.1
dep command did you run?dep ensure
go build
Expected that the project built correctly
test/vendor/github.com/ethereum/go-ethereum/crypto/secp256k1
vendor/github.com/ethereum/go-ethereum/crypto/secp256k1/curve.go:43:10: fatal error: libsecp256k1/include/secp256k1.h: No such file or directory #include "libsecp256k1/include/secp256k1.h"
I came across the same issue and determined that for go-ethereum I had to specify:
[[prune.project]]
name = "github.com/ethereum/go-ethereum"
non-go = false
unused-packages = false
specifically, setting unused-packages = false for pruning option for go-ethereum. There must be an edge case throwing off dep for pruning unused packages that use a C library
Sorry i didn't respond at the time, but yes, @pkieltyka has the expected resolution. Glad you folks got this sorted!
@pkieltyka 3Q very much.It is very helpful
Most helpful comment
I came across the same issue and determined that for go-ethereum I had to specify:
specifically, setting
unused-packages = falsefor pruning option for go-ethereum. There must be an edge case throwing off dep for pruning unused packages that use a C library