diff options
author | andybons <andybons@chromium.org> | 2015-08-24 14:37:09 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-08-24 21:39:36 +0000 |
commit | 3322f7611ba1444e553b2cce4de3a1a32ad46e72 (patch) | |
tree | dfb6bbea413da0581b8d085b184a5e6ceea5af3e /docs/linux_chromium_arm.md | |
parent | 5d58c9eb2baa203be1b84ac88cde82c59d72f143 (diff) | |
download | chromium_src-3322f7611ba1444e553b2cce4de3a1a32ad46e72.zip chromium_src-3322f7611ba1444e553b2cce4de3a1a32ad46e72.tar.gz chromium_src-3322f7611ba1444e553b2cce4de3a1a32ad46e72.tar.bz2 |
Per https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/irLAQ8f8uGk
Initial migration of wiki content over to src/docs
There will be a follow-up CL to ensure docs are following chromium’s style guide, links are fixed, etc. The file auditing was becoming too much for a single change and per Nico’s suggestion, it seems to be better to do
+ Bulk import with initial prune.
+ Follow-up CLs to clean up the documentation.
So that each CL has its own purpose.
BUG=none
Review URL: https://codereview.chromium.org/1309473002
Cr-Commit-Position: refs/heads/master@{#345186}
Diffstat (limited to 'docs/linux_chromium_arm.md')
-rw-r--r-- | docs/linux_chromium_arm.md | 123 |
1 files changed, 123 insertions, 0 deletions
diff --git a/docs/linux_chromium_arm.md b/docs/linux_chromium_arm.md new file mode 100644 index 0000000..927be6e --- /dev/null +++ b/docs/linux_chromium_arm.md @@ -0,0 +1,123 @@ +Note this currently contains various recipes: + + + +--- + + +# Recipe1: Building for an ARM CrOS device +This recipe uses `ninja` (instead of `make`) so its startup time is much lower (sub-1s, instead of tens of seconds), is integrated with goma (for google-internal users) for very high parallelism, and uses `sshfs` instead of `scp` to significantly speed up the compile-run cycle. It has moved to https://sites.google.com/a/chromium.org/dev/developers/how-tos/-quickly-building-for-cros-arm-x64 (mostly b/c of the ease of attaching files to sites). + + + +--- + + +# Recipe2: Explicit Cross compiling + +Due to the lack of ARM hardware with the grunt to build Chromium native, cross compiling is currently the recommended method of building for ARM. + +These instruction are designed to run on Ubuntu Precise. + +### Installing the toolchain + +The install-build-deps script can be used to install all the compiler +and library dependencies directly from Ubuntu: + +``` +$ ./build/install-build-deps.sh --arm +``` + +### Installing the rootfs + +A prebuilt rootfs image is kept up-to-date on Cloud Storage. It will +automatically be installed by gclient runhooks installed if you have 'target\_arch=arm' in your GYP\_DEFINES. + +To install the sysroot manually you can run: +``` +$ ./chrome/installer/linux/sysroot_scripts/install-debian.wheezy.sysroot.py --arch=arm +``` + +### Building + +To build for ARM, using the clang binary in the chrome tree, use the following settings: + +``` +export GYP_CROSSCOMPILE=1 +export GYP_DEFINES="target_arch=arm" +``` + +There variables need to be set at gyp-time (when you run gyp\_chromium), +but are not needed at build-time (when you run make/ninja). + +## Testing + +### Automated Build and Testing + +Chromium's testing infrastructure for ARM/Linux is (to say the least) +in its infancy. There are currently two builders setup, one on the +FYI waterfall and one the the trybot waterfall: + +http://build.chromium.org/p/chromium.fyi/builders/Linux%20ARM%20Cross-Compile +http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_arm + + +These builders cross compile on x86-64 and then trigger testing +on real ARM hard bots: + +http://build.chromium.org/p/chromium.fyi/builders/Linux%20ARM%20Tests%20%28Panda%29/ +http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_arm_tester + +Unfortunately, even those the builders are usually green, the testers +are not yet well maintained or monitored. + +There is compile-only trybot and fyi bot also: + +http://build.chromium.org/p/chromium.fyi/builders/Linux%20ARM +http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_arm_compile + +### Testing with QEMU + +If you don't have a real ARM machine, you can test with QEMU. For instance, there are some prebuilt QEMU Debian images here: http://people.debian.org/~aurel32/qemu/. Another option is to use the rootfs generated by rootstock, as mentioned above. + +Here's a minimal xorg.conf if needed: + +``` +Section "InputDevice" + Identifier "Generic Keyboard" + Driver "kbd" + Option "XkbRules" "xorg" + Option "XkbModel" "pc105" + Option "XkbLayout" "us" +EndSection + +Section "InputDevice" + Identifier "Configured Mouse" + Driver "mouse" +EndSection + +Section "Device" + Identifier "Configured Video Device" + Driver "fbdev" + Option "UseFBDev" "true" +EndSection + +Section "Monitor" + Identifier "Configured Monitor" +EndSection + +Section "Screen" + Identifier "Default Screen" + Monitor "Configured Monitor" + Device "Configured Video Device" + DefaultDepth 8 + SubSection "Display" + Depth 8 + Modes "1024x768" "800x600" "640x480" + EndSubSection +EndSection +``` + +### Notes + * To building for thumb reduces the stripped release binary by around 9MB, equating to ~33% of the binary size. To enable thumb, set 'arm\_thumb': 1 + * TCmalloc does not have an ARM port, so it is disabled.
\ No newline at end of file |