[mirror] Go on Mobile
https://golang.org/x/mobile
3bd69d3fcc
Compiling a binary with "-tags gldebug" will add log tracing to each GL function call. This is the best I can offer in lieu of of real error handling. A colleague has accused me of Aspect-oriented programming. The wikipedia article on the topic lost me in the first paragraph, so just for the record, this was inspired by the way the cover tool rewrites source code. LGTM=sameer R=golang-codereviews, sameer CC=golang-codereviews https://golang.org/cl/128640043 |
||
---|---|---|
app | ||
bind | ||
cmd/gobind | ||
example | ||
gl | ||
.hgignore | ||
AUTHORS | ||
CONTRIBUTORS | ||
LICENSE | ||
PATENTS | ||
README | ||
codereview.cfg |
README
The go.mobile repository holds libraries and build tools for Go on Android. This is early stage work. The build system integration is not ready. For now, 1. Install Android Studio. 2. Install the Android NDK. 3. Pick a home for the standalone NDK toolchain and set an environment variable: NDK_ROOT=$HOME/android/ndk-toolchain 4. Confiure the NDK toolchain: ndk/build/tools/make-standalone-toolchain.sh \ --platform=android-9 --install-dir=$NDK_ROOT 5. Create an android App in studio, then set ANDROID_APP=$HOME/android/studio/yourapp/app With these two environment variables, the make.bash script in go.mobile/example/hello_jni builds a .so file and symlinks in the necessary java files to the project. To submit changes to this repository, see http://golang.org/doc/contribute.html.