runtime: darwin using -buildmode=c-shared so got runtime: unexpected return pc for runtime.sigpanic called from 0x41e745a #40131
Comments
Thank you for this report @wangzhione and welcome to the Go project! I can reproduce this even for Go1.13.12, Go1.12.17, but for Go1.11.13 there are CGO errors. Kindly paging @ianlancetaylor @cherrymui |
I tried to debug this problem, it crashed at method
It looks like the
Then I tried to add many
But I still do not know why the shared library was accessing the wrong
any thoughts? |
A shared library built with I don't know whether the Mach-O symbol visibility rules can support using |
Emmanual @odeke-em found that Go 1.11 gave a CGO error, not a segfault. |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
yes
What operating system and processor architecture are you using (
go env
)?go env
Outputuname -a
OutputWhat did you do?
verify.go
sec/key.go
go build genrate c-shared .so
go build -buildmode=c-shared -a -o libverify.so verify.go
using libverify.so
What did you expect to see?
no panic, and print out a string.
What did you see instead?
The text was updated successfully, but these errors were encountered: