golang/go

cmd/go: with -compiler=gccgo, only call runtime.setmodinfo if using a version of gccgo that supports it

开放

#42,916 创建于 2020年12月1日

 (6 条评论) (0 个反应) (0 位负责人)Go (19,008 个派生)batch import
GoCommandNeedsFixhelp wanted

仓库指标

星标
 (133,883 个星标)
PR 合并指标
 (30 天内没有已合并 PR)

描述

What version of Go are you using (go version)?

Does this issue reproduce with the latest release?

No. It is on tip only.

$ gccgo --version
gccgo (Debian 8.3.0-6) 8.3.0
Copyright (C) 2018 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE

What operating system and processor architecture are you using (go env)?

What did you do?

go run -compiler=gccgo example.go

What did you expect to see?

Normal run.

What did you see instead?

# command-line-arguments
/usr/bin/ld: $WORK/b001/_pkg_.a(_go_.o): in function `main.main..init0':
/tmp/go-build/b001/_gomod_.go:5: undefined reference to `runtime.setmodinfo

It is on Debian 10 stable.

贡献者指南