go build gcc报错 /usr/bin/ld | cannot find -ldl cannot find -lpthread cannot find -lc

之前一直在kali或者其他ubuntu设备编译sliver, 临时在centos7上编译时报错了

# github.com/bishopfox/sliver/server
/usr/local/go/pkg/tool/linux_amd64/link: running gcc failed: exit status 1
/usr/bin/ld: cannot find -ldl
/usr/bin/ld: cannot find -lpthread
/usr/bin/ld: cannot find -lc
collect2: error: ld returned 1 exit status

查了下资料,引用(https://www.xiaobinqt.cn/build-running-gcc-failed/)解决方案;

yum install glibc-static.x86_64 -y
posted @   干炸小黄鱼  阅读(229)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· 地球OL攻略 —— 某应届生求职总结
· 周边上新:园子的第一款马克杯温暖上架
· Open-Sora 2.0 重磅开源!
· 提示词工程——AI应用必不可少的技术
· .NET周刊【3月第1期 2025-03-02】
点击右上角即可分享
微信分享提示