-
-
Notifications
You must be signed in to change notification settings - Fork 229
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
Dep. problem cross-compiling to Android. #252
Comments
We don't have a nice out-of-the-box support for Android yet but @gen2brain has kindly provided an example of using go-sdl2 on Android for us plebs at https://github.com/gen2brain/go-sdl2-android-example. I personally haven't tried it but perhaps it can help you. It's definitely something that can be improved so I can keep this issue open. |
Thank you! I will try to follow @gen2brain steps/organization. The content covering gomobile across the web is very scarce (and most of the non-official came to be by the time of the initial release and is kinda outdated), any sort of good example is very valuable! Edit: Looking into @gen2brain go-sdl2-android-example looks like a "hack" project from times when gomobile didn't exist yet. It is quite complex and basically does what gomobile try to solve, but hasn't been updated in a while. I will try to ask for help at golang/go/x as well and keep you informed in case of success! Edit2: Here's the issue I just opened at golang repo. |
@billyninja now you can use prebuilt libraries for Android, and other arches, with To build binary for Android, you need just NDK and something like this can be used: But such binary is not much useful on Android. I will see these days if I can update https://github.com/gen2brain/go-sdl2-android-example and if that turns out nice maybe also to include it in official examples here. Btw. gomobile is not useful for this, maybe just to compile shared lib in .aar file, but for that you cannot use you app as |
New Android example, much simpler https://github.com/veandco/go-sdl2-examples/tree/master/examples/android . |
Having a hard time cross-compiling a program to android/arm. It complains about missing X11/Xlib.h. While a regular x86_64 build works just fine. Sure it is more related to the SDL2 itself, but either way if you guys could lend me a hand.
The program itself doesn't do anything special, it's a regular ~100 loc go-sdl2 program.
The text was updated successfully, but these errors were encountered: