go 问题记录

栏目: Go · 发布时间: 5年前

内容简介:/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 只保留一个即可。注意要查看项目引用的项目是否也有


以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网

查看所有标签

猜你喜欢:

本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们

Weaving the Web

Weaving the Web

Tim Berners-Lee / Harper Paperbacks / 2000-11-01 / USD 15.00

Named one of the greatest minds of the 20th century by Time , Tim Berners-Lee is responsible for one of that century's most important advancements: the world wide web. Now, this low-profile genius-wh......一起来看看 《Weaving the Web》 这本书的介绍吧!

JSON 在线解析
JSON 在线解析

在线 JSON 格式化工具

HEX CMYK 转换工具
HEX CMYK 转换工具

HEX CMYK 互转工具

HEX HSV 转换工具
HEX HSV 转换工具

HEX HSV 互换工具