diff options
author | Ben Shi <powerman1st@163.com> | 2018-05-09 04:11:12 +0000 |
---|---|---|
committer | Elias Naur <elias.naur@gmail.com> | 2018-05-10 14:44:52 +0000 |
commit | f95ef94ad5f58aef9a17bae407bf7b154caabe11 (patch) | |
tree | 479b2cca6d84f4310c0ba04d70abc08acd3cb671 /misc/android | |
parent | bf23a4e61ddceb26744da8f462ce6351fca66089 (diff) | |
download | go-f95ef94ad5f58aef9a17bae407bf7b154caabe11.tar.gz go-f95ef94ad5f58aef9a17bae407bf7b154caabe11.zip |
misc/android: add more information to README
Add more information to misc/android/README for developing
arm and arm64 with an Android environment.
Change-Id: I0c88996b6ab0c41946a2c7e69e9c92ec7bb3be27
Reviewed-on: https://go-review.googlesource.com/112276
Reviewed-by: Elias Naur <elias.naur@gmail.com>
Diffstat (limited to 'misc/android')
-rw-r--r-- | misc/android/README | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/misc/android/README b/misc/android/README index 7b17d879e8..a0dd8500ee 100644 --- a/misc/android/README +++ b/misc/android/README @@ -8,4 +8,17 @@ mobile subrepository: To run the standard library tests, see androidtest.bash. Run it as - CC_FOR_TARGET=.../ndk-gcc GOARCH=arm GOARM=7 ./androidtest.bash + CC_FOR_TARGET=$STANDALONE_NDK_PATH/bin/clang GOARCH=arm64 ./androidtest.bash + +To create a standalone android NDK tool chain, follow the instructions on + + https://developer.android.com/ndk/guides/standalone_toolchain + +To run tests on the Android device, add the bin directory to PATH so the +go tool can find the go_android_$GOARCH_exec wrapper generated by +androidtest.bash. Then, use the same GOARCH as when androidtest.bash ran +and set GOOS to android. For example, to run the go1 benchmarks + + export PATH=$GOROOT/bin:$PATH + cd $GOROOT/test/bench/go1/ + GOOS=android GOARCH=arm64 go test -bench=. -count=N -timeout=T
\ No newline at end of file |