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

x/mobile: java.lang.UnsatisfiedLinkError: Native method not found: go.Seq.init:()V on API 19 #19492

Open
justmax437 opened this Issue Mar 10, 2017 · 1 comment

Comments

Projects
None yet
4 participants
@justmax437

justmax437 commented Mar 10, 2017

Please answer these questions before submitting your issue. Thanks!

What version of Go are you using (go version)?

go version go1.7.5 linux/amd64

What operating system and processor architecture are you using (go env)?

GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/max/dev/workspace/go"
GORACE=""
GOROOT="/home/max/dev/go"
GOTOOLDIR="/home/max/dev/go/pkg/tool/linux_amd64"
CC="gcc"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build775467473=/tmp/go-build -gno-record-gcc-switches"
CXX="g++"
CGO_ENABLED="1"

What did you do?

I'm building a simple native library with gomobile bind. On Android Kitkat, my app, built with aar created by gomobile crashes on some devices. I'm getting crash reports like that:

Exception java.lang.UnsatisfiedLinkError: Native method not found: go.Seq.init:()V
go.Seq.init (Seq.java)
go.Seq.<clinit> (Seq.java)
com.justmax437.sigcheck.Sigcheck. (Sigcheck.java)
...

Not sure if older versions also affected, my minSdkVersion is 19. Lolipop and newer seems to work as expected, no such crashes there.

@ALTree ALTree added this to the Unreleased milestone Mar 10, 2017

@bradfitz bradfitz added the mobile label Jul 20, 2017

@eliasnaur

This comment has been minimized.

Contributor

eliasnaur commented Mar 16, 2018

Is that the full crash trace? I suspect this error is caused by failing to load and initialize the Go native JNI library.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment