merge in old CLs to new jd files
Change-Id: Iee99364f6a99270fee5f4fdb766ec39fb51a74d1
diff --git a/src/source/building-kernels.jd b/src/source/building-kernels.jd
index 0b20a50..3cc6c1e 100644
--- a/src/source/building-kernels.jd
+++ b/src/source/building-kernels.jd
@@ -31,16 +31,98 @@
clone steps other than the step to download the actual kernel sources.</p>
<p>We will use the Pandaboard kernel in all the following examples.</p>
<h2 id="figuring-out-which-kernel-to-build">Figuring out which kernel to build</h2>
-<p>You will want to look at the git log for the kernel in the device project that
-you are interested in.
+<p>This table lists the name and locations of the kernel sources and binaries:
+<table>
+ <tr>
+ <th>Device</th>
+ <th>Binary location</th>
+ <th>Source location</th>
+ <th>Build configuration</th>
+ </tr>
+ <tr>
+ <td>manta</td>
+ <td>device/samsung/manta/kernel</td>
+ <td>kernel/exynos</td>
+ <td>manta_defconfig</td>
+ </tr>
+ <tr>
+ <td>mako</td>
+ <td>device/lge/mako-kernel/kernel</td>
+ <td>kernel/msm</td>
+ <td>mako_defconfig</td>
+ </tr>
+ <tr>
+ <td>grouper</td>
+ <td>device/asus/grouper/kernel</td>
+ <td>kernel/tegra</td>
+ <td>tegra3_android_defconfig</td>
+ </tr>
+ <tr>
+ <td>tilapia</td>
+ <td>device/asus/grouper/kernel</td>
+ <td>kernel/tegra</td>
+ <td>tegra3_android_defconfig</td>
+ </tr>
+ <tr>
+ <td>maguro</td>
+ <td>device/samsung/tuna/kernel</td>
+ <td>kernel/omap</td>
+ <td>tuna_defconfig</td>
+ </tr>
+ <tr>
+ <td>toro</td>
+ <td>device/samsung/tuna/kernel</td>
+ <td>kernel/omap</td>
+ <td>tuna_defconfig</td>
+ </tr>
+ <tr>
+ <td>panda</td>
+ <td>device/ti/panda/kernel</td>
+ <td>kernel/omap</td>
+ <td>panda_defconfig</td>
+ </tr>
+ <tr>
+ <td>stingray</td>
+ <td>device/moto/wingray/kernel</td>
+ <td>kernel/tegra</td>
+ <td>stingray_defconfig</td>
+ </tr>
+ <tr>
+ <td>wingray</td>
+ <td>device/moto/wingray/kernel </td>
+ <td>kernel/tegra</td>
+ <td>stingray_defconfig</td>
+ </tr>
+ <tr>
+ <td>crespo</td>
+ <td>device/samsung/crespo/kernel</td>
+ <td>kernel/samsung</td>
+ <td>herring_defconfig</td>
+ </tr>
+ <tr>
+ <td>crespo4g</td>
+ <td>device/samsung/crespo/kernel</td>
+ <td>kernel/samsung</td>
+ <td>herring_defconfig</td>
+ </tr>
+</table>
+
+<p>You will want to look at the git log for the kernel binary in the device
+project that you are interested in.</p>
+
+
+
Device projects are of the form device/<vendor>/<name>.</p>
<pre><code>$ git clone https://android.googlesource.com/device/ti/panda
$ cd panda
-$ git log kernel
+$ git log --max-count=1 kernel
</code></pre>
-<p>The log should contain notes of the commit SHA1 for the appropriate
-kernel project. Keep this value at hand so that you can use it in
-a later step.</p>
+
+<p>The commit message for the kernel binary contains a partial git log
+of the kernel sources that were used to build the binary in question.
+The first entry in the log is the most recent, i.e. the one used to
+build that kernel. You will need it at a later step.</p>
+
<h2 id="downloading-sources">Downloading sources</h2>
<p>Depending on which kernel you want,</p>
<pre><code>$ git clone https://android.googlesource.com/kernel/common.git
@@ -67,9 +149,15 @@
</ul>
<h2 id="downloading-a-prebuilt-gcc">Downloading a prebuilt gcc</h2>
<p>Ensure that the prebuilt toolchain is in your path.</p>
-<pre><code>$ git clone https://android.googlesource.com/platform/prebuilt
-$ export PATH=$(pwd)/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin:$PATH
-</code></pre>
+<pre>$ export PATH=$(pwd)/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin:$PATH</pre>
+
+or
+<pre>$ export PATH=$(pwd)/prebuilts/gcc/darwin-x86/arm/arm-eabi-4.6/bin:$PATH</pre>
+
+<p>On a linux host, if you don't have an Android source tree, you can download
+the prebuilt toolchain from:
+<pre>$ git clone https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6</pre>
+
<h2 id="building">Building</h2>
<p>As an example, we would build the panda kernel using the following commands:</p>
<pre><code>$ export ARCH=arm
@@ -82,14 +170,7 @@
</code></pre>
<p>To build the tuna kernel, you may run the previous commands replacing all
instances of "panda" with "tuna".</p>
-<ul>
-<li>The kernel for mantaray is <code>device/samsung/manta/kernel</code></li>
-<li>The kernel for mako is <code>device/lge/mako-kernel/kernel</code></li>
-<li>The kernel for grouper and tilapia is <code>device/asus/grouper/kernel</code></li>
-<li>The kernel for maguro and toro is <code>device/samsung/tuna/kernel</code></li>
-<li>The kernel for crespo and crespo4g is <code>device/samsung/crespo/kernel</code></li>
-<li>The kernel for stingray and wingray is <code>device/moto/wingray/kernel</code></li>
-</ul>
-<p>The image is output as <code>arch/arm/boot/zImage</code>. You may copy it as
-<code>device/<vendor>/<name>/kernel</code> or <code>device/ti/panda/kernel</code> in the case of this
-example.</p>
+<p>
+The kernel binary is output as `arch/arm/boot/zImage`, and needs to be copied
+into the Android source tree in order to build the matching boot image.
+</p>
\ No newline at end of file