在Windows中编译Go文件?

发布于 2024-11-10 03:33:56 字数 219 浏览 2 评论 0原文

我正在尝试学习 Go 并已安装 Go MinGW 但我不知道如何操作在任何地方实际编译 .go 文件。这是直接从 Windows 支持的 Go wiki 链接的程序,但所有教程都讨论使用 6g 和 gccgo 等进行编译,而这些在我的 Windows 机器上都不起作用。

I am trying to learn Go and have installed Go MinGW but I cannot find out how to actually compile a .go file ANYWHERE. This is the program linked directly from the Go wiki for Windows Support, but all the tutorials talk about using 6g and gccgo etc. to compile and none of those work from my windows machine.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

指尖上得阳光 2024-11-17 03:33:56

我很笨,链接的文件是 32 位,我使用“6g”进行编译,因为我的系统是 64 位。 “8g”可以编译。
“8g myfile.go”
“8l myfile.8”
“myfile.out”
努力让它运行。

I'm dumb, the file linked is 32 bit and I was using "6g" to compile because my system is 64 bit. "8g" works to compile.
"8g myfile.go"
"8l myfile.8"
"myfile.out"
Works to get it running.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文