How to handle go dependencies

Matthias Fechner idefix at fechner.net
Sat Jul 6 17:52:12 UTC 2019


Dear Dmitri,

at first thanks a lot for your suggestions.
The current version of the Makefile is always here:
https://gitlab.fechner.net/mfechner/Gitlab/blob/12.0/devel/gitaly/Makefile

Other answer under your suggestions.

Am 23.06.2019 um 23:40 schrieb Dmitri Goutnik via freebsd-ports:
> +USES= gmake 

I used now USES= gmake |go:no_targets|

|This pulls in go as dependency. Without go:no_targets I got an error
message that go was not found.
|

|
|

> "gitaly-proto" is not a valid group name (contains "-"); can be fixed by 
> changing the group name to e.g. "gitaly_proto"

thanks, now I was able to generate the distinfo file.

>  post-patch:
>  	${REINPLACE_CMD} -e "s|%%PREFIX%%|${PREFIX}|" ${WRKSRC}/config.toml.example
>  	${MV} ${WRKSRC}/config.toml.example ${WRKSRC}/config.toml.sample
> -	${RM} ${WRKSRC}/go.mod

removed.

But now I have the problem that go does not find the libs.
I get now the error messages like:
# go install
go: finding github.com/getsentry/raven-go v0.1.2
go: finding golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4
go: finding github.com/golang/protobuf v1.3.1
go: finding gitlab.com/gitlab-org/gitaly-proto v1.32.0
go: finding github.com/stretchr/testify v1.2.2
go: finding github.com/cloudflare/tableflip
v0.0.0-20190329062924-8392f1641731
go: finding github.com/tinylib/msgp v1.1.0
go: finding github.com/sirupsen/logrus v1.2.0
go: finding github.com/libgit2/git2go v0.0.0-20190104134018-ecaeb7a21d47
go: finding github.com/BurntSushi/toml v0.3.1
go: github.com/BurntSushi/toml at v0.3.1: Get
https://proxy.golang.org/github.com/%21burnt%21sushi/toml/@v/v0.3.1.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: github.com/getsentry/raven-go at v0.1.2: Get
https://proxy.golang.org/github.com/getsentry/raven-go/@v/v0.1.2.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: github.com/cloudflare/tableflip at v0.0.0-20190329062924-8392f1641731:
Get
https://proxy.golang.org/github.com/cloudflare/tableflip/@v/v0.0.0-20190329062924-8392f1641731.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: github.com/sirupsen/logrus at v1.2.0: Get
https://proxy.golang.org/github.com/sirupsen/logrus/@v/v1.2.0.info: dial
tcp 172.217.19.209:443: connect: can't assign requested address
go: finding google.golang.org/grpc v1.16.0
go: finding google.golang.org/genproto v0.0.0-20181202183823-bd91e49a0898
go: github.com/libgit2/git2go at v0.0.0-20190104134018-ecaeb7a21d47: Get
https://proxy.golang.org/github.com/libgit2/git2go/@v/v0.0.0-20190104134018-ecaeb7a21d47.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: finding github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0
go: github.com/stretchr/testify at v1.2.2: Get
https://proxy.golang.org/github.com/stretchr/testify/@v/v1.2.2.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: finding gopkg.in/yaml.v2 v2.2.2
go: golang.org/x/sync at v0.0.0-20181221193216-37e7f081c4d4: Get
https://proxy.golang.org/golang.org/x/sync/@v/v0.0.0-20181221193216-37e7f081c4d4.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: finding gitlab.com/gitlab-org/labkit v0.0.0-20190221122536-0c3fc7cdd57c
go: finding github.com/prometheus/client_golang v0.9.3
go: github.com/tinylib/msgp at v1.1.0: Get
https://proxy.golang.org/github.com/tinylib/msgp/@v/v1.1.0.info: dial
tcp 172.217.19.209:443: connect: can't assign requested address
go: github.com/golang/protobuf at v1.3.1: Get
https://proxy.golang.org/github.com/golang/protobuf/@v/v1.3.1.info: dial
tcp 172.217.19.209:443: connect: can't assign requested address
go: gitlab.com/gitlab-org/gitaly-proto at v1.32.0: Get
https://proxy.golang.org/gitlab.com/gitlab-org/gitaly-proto/@v/v1.32.0.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: finding github.com/kelseyhightower/envconfig v1.3.0
go: finding golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a
go: finding golang.org/x/net v0.0.0-20190311183353-d8887717615a
go: finding github.com/grpc-ecosystem/go-grpc-middleware v1.0.0
go: gitlab.com/gitlab-org/labkit at v0.0.0-20190221122536-0c3fc7cdd57c: Get
https://proxy.golang.org/gitlab.com/gitlab-org/labkit/@v/v0.0.0-20190221122536-0c3fc7cdd57c.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: github.com/grpc-ecosystem/go-grpc-middleware at v1.0.0: Get
https://proxy.golang.org/github.com/grpc-ecosystem/go-grpc-middleware/@v/v1.0.0.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: golang.org/x/net at v0.0.0-20190311183353-d8887717615a: Get
https://proxy.golang.org/golang.org/x/net/@v/v0.0.0-20190311183353-d8887717615a.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: github.com/grpc-ecosystem/go-grpc-prometheus at v1.2.0: Get
https://proxy.golang.org/github.com/grpc-ecosystem/go-grpc-prometheus/@v/v1.2.0.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: google.golang.org/genproto at v0.0.0-20181202183823-bd91e49a0898: Get
https://proxy.golang.org/google.golang.org/genproto/@v/v0.0.0-20181202183823-bd91e49a0898.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: golang.org/x/sys at v0.0.0-20190215142949-d0b11bdaac8a: Get
https://proxy.golang.org/golang.org/x/sys/@v/v0.0.0-20190215142949-d0b11bdaac8a.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: gopkg.in/yaml.v2 at v2.2.2: Get
https://proxy.golang.org/gopkg.in/yaml.v2/@v/v2.2.2.info: dial tcp
172.217.19.209:443: connect: can't assign requested address
go: github.com/kelseyhightower/envconfig at v1.3.0: Get
https://proxy.golang.org/github.com/kelseyhightower/envconfig/@v/v1.3.0.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: github.com/prometheus/client_golang at v0.9.3: Get
https://proxy.golang.org/github.com/prometheus/client_golang/@v/v0.9.3.info:
dial tcp 172.217.19.209:443: connect: can't assign requested address
go: google.golang.org/grpc at v1.16.0: Get
https://proxy.golang.org/google.golang.org/grpc/@v/v1.16.0.info: dial
tcp 172.217.19.209:443: connect: can't assign requested address
go: error loading module requirements

If I execute the following command:
poudriere testport -p gitlab -j 120amd64 -i devel/gitaly

I can go into the directory:
cd
/wrkdirs/usr/ports/devel/gitaly/work/gitaly-333775253533ae4e9e9e66dc12b636821646551f-333775253533ae4e9e9e66dc12b636821646551f/vendor/github.com/BurntSushi/toml/

So it seems it exists now but go does not find it.

Do you have any idea?


Gruß
Matthias

-- 

"Programming today is a race between software engineers striving to
build bigger and better idiot-proof programs, and the universe trying to
produce bigger and better idiots. So far, the universe is winning." --
Rich Cook



More information about the freebsd-ports mailing list