chai2010/advanced-go-programming-book

ch3.1 问题

kongminhao opened this issue · 2 comments

提示:哪一章节的问题,建议如何修改

main 函数定义的那一章节。

此代码在go 1.13无法运行,报错如下。

go build -o a.out && ./a.out
# chai2010.cn/gobook/examples/ch3.1/main-01
main.main: relocation target runtime.printstring not defined for ABI0 (but is defined for ABIInternal)
main.main: relocation target runtime.printnl not defined for ABI0 (but is defined for ABIInternal)
make: [default] Error 2 (ignored)
rm: a.out: No such file or directory
make: [default] Error 1 (ignored)
go version
go version go1.13 darwin/amd64

Go汇编函数的ABI发生了变化,可以参考这里的方案 #427

Thanks♪(・ω・)ノ