-
Notifications
You must be signed in to change notification settings - Fork 17.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
runtime: fatal error: invalid runtime symbol table. runtime: panic before malloc heap initialized #43969
Comments
fatal error: invalid runtime symbol table. runtime: panic before malloc heap initialized
do you have a minimal reproducible example of a project that triggers this? |
@seankhliao Thanks for your reply. In this repo, you can see integration of WireGuard and DNSCrypt in single target. Because of this, runtime symbol table error occurs. Thank you. |
CC @cherrymui |
Could you share how you build the program? In particular, what build mode do you use to build the Go part, and how do you put pieces together? Do you use shared libraries? Thanks. |
@cherrymui This example repository is a native application for IOS build in Swift language. |
Okay, https://github.com/abhi-m-simformsolutons/GoCheck/tree/master/WireGuardKitGo has Go code (the only Go source code in the repo). Its Makefile builds it as a c-archive. https://github.com/abhi-m-simformsolutons/GoCheck/blob/master/WireGuardCheck/Dnscryptproxy.framework/Versions/A/Dnscryptproxy is a binary blob, which is actually a Go c-archive. (For the future, don't include binary blobs, but the source code and how to build it. Thanks.) So this is about including two Go c-archives in the same executable, and the _cgo_topofstack symbol in one module is somehow resolved to other module and causing the "symbol table not sorted" error. I'm not sure including two Go c-archives in the same executable is supported (could be, I'd need to look into more). We might be able to make it work. Could you try if you get the same failure with Go 1.16beta or Go tip? |
See previously #30822 (comment). |
Thanks @bcmills ! Okay, so this is not going to work. Please try building the two Go parts into a single c-archive? Thanks. |
I wonder if this problem was solved, and how did you solve it. |
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
OutputWhat did you do?
In XCode, I am working with network related things.
For that, I integrate DNSCrypt and WireGuard.This both are in GO Language.
Individual integration of these SDK will works fine in XCode project. But, When I integrate these two SDK in the same project(Target) at a same time it throws an error.
I also refered this issue: #18190
What did you expect to see?
Build and Run Xcode Project Successfully.
What did you see instead?
function symbol table not sorted by program counter
The text was updated successfully, but these errors were encountered: