Revision: 12183
Author: [email protected]
Date: Wed Jul 25 02:28:07 2012
Log: Edited wiki page D8OnAndroid through web user interface.
http://code.google.com/p/v8/source/detail?r=12183
Modified:
/wiki/D8OnAndroid.wiki
=======================================
--- /wiki/D8OnAndroid.wiki Thu Jul 12 07:34:28 2012
+++ /wiki/D8OnAndroid.wiki Wed Jul 25 02:28:07 2012
@@ -2,26 +2,26 @@
=Prerequisites=
- * a Linux workstation
- * v8 r10409 or later
+ * a Linux/Mac workstation
+ * v8 r12178 or later
* an Android device and matching USB cable
* make sure [http://code.google.com/p/v8/wiki/BuildingWithGYP building
with GYP] works
=Get the Android NDK=
- * tested versions: r6b, r7
+ * tested versions: `r7`
* download the NDK from http://developer.android.com/sdk/ndk/index.html
* extract it
* in a shell, `cd` to the extracted NDK's root directory, and from there
run:
{{{
build/tools/make-standalone-toolchain.sh --platform=android-9
--install-dir=toolchain
}}}
- "--platform=android-9" is for Gingerbread and above; please note that you
*have to* use "--install-dir=toolchain" for the `make` command below to
work!
+ "`--platform=android-9`" is for Gingerbread and above; please note that
you *have to* use "`--install-dir=toolchain`" for the `make` command below
to work!
* export `$ANDROID_NDK_ROOT` in your shell (or `~/.bashrc`, or whatever)
=Get the Android SDK=
- * tested version: r15
+ * tested version: `r15`
* download the SDK from http://developer.android.com/sdk/index.html
* extract it
* install the "Platform tools" using the SDK manager that you can start
by running `tools/android`
@@ -49,27 +49,32 @@
=Compile V8 for Android=
+Currently two architectures (`android_arm` and `android_ia32`) are
supported, each in `debug` or `release` mode.
* compile:
{{{
-make android -j16
+make android_arm.release -j16
}}}
* push the resulting binary to the device:
{{{
-adb push out/android.release/d8 /data/local/v8/d8
+adb push out/android_arm.release/d8 /data/local/v8/d8
}}}
* the most comfortable way to run it is from your workstation's shell as
a one-off command (rather than starting an interactive shell session on the
device), that way you can use pipes or whatever to process the output as
necessary:
{{{
adb shell /data/local/v8/d8 <parameters>
}}}
* warning: when you cancel such an "adb shell whatever" command using
Ctrl+C, the process on the phone will sometimes keep running.
+ * Alternatively, use the `.check` suffix to automatically push test
binaries and test cases onto the device and run them.
+{{{
+make android_arm.release.check
+}}}
=Profile=
* compile a binary, push it to the device, keep a copy of it on the host
{{{
-make android -j16
-adb push out/android.release/d8 /data/local/v8/d8-version.under.test
-cp out/android.release/d8 ./d8-version.under.test
+make android_arm.release -j16
+adb push out/android_arm.release/d8 /data/local/v8/d8-version.under.test
+cp out/android_arm.release/d8 ./d8-version.under.test
}}}
* get a profiling log and copy it to the host:
{{{
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev