内容简介:/usr/lib/go-1.10/pkg/tool/linux_amd64/link: running gcc failed: exit status 1/tmp/go-link-008006128/000026.o: In function/tmp/go-link-008006128/000024.o:/tmp/go-build/cgo-gcc-prolog:32: first defined here
go 问题记录
/usr/lib/go-1.10/pkg/tool/linux_amd64/link: running gcc failed: exit status 1
/tmp/go-link-008006128/000026.o: In function _cgo_05dc84caff82_Cfunc_sysconf': /tmp/go-build/cgo-gcc-prolog:32: multiple definition of
_cgo_05dc84caff82_Cfunc_sysconf’
/tmp/go-link-008006128/000024.o:/tmp/go-build/cgo-gcc-prolog:32: first defined here
collect2: error: ld returned 1 exit status
解决办法:
linux: export CGO_ENABLED=0 windows : cmd: set CGO_ENABLED=0 powershell:$env:CGO_ENABLED=0
https://github.com/golang/go/issues/15038
panic: /debug/requests is already registered. You may have two independent copies of golang.org/x/net/trace in your binary, trying to maintain separate state. This may involve a vendored copy of golang.org/x/net/trace .
解决办法: olang.org/x/net/trace这个重复了,删除所有的引用的或者系统的olang.org/x/net/的trace 只保留一个即可。注意要查看项目引用的项目是否也有
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网
猜你喜欢:本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。