[git commit] "Building on an Android tablet"

Denys Vlasenko vda.linux at googlemail.com
Fri Mar 25 20:40:31 UTC 2016


commit: https://git.busybox.net/busybox-website/commit/?id=6820c5f44fc2733d61b662b7797674ba825838ef
branch: https://git.busybox.net/busybox-website/commit/?id=refs/heads/master

Signed-off-by: Denys Vlasenko <vda.linux at googlemail.com>
---
 news.html | 31 +++++++++++++++++++++++++++++++
 1 file changed, 31 insertions(+)

diff --git a/news.html b/news.html
index 5a5dcff..bf723ed 100644
--- a/news.html
+++ b/news.html
@@ -31,6 +31,37 @@
     </p>
   </li>
 
+  <li><b>25 March 2016 -- Building on an Android tablet.</b>
+    <p>Android is based on Linux kernel, but sadly and unexplicably,
+    Android userspace is not Unix-friendly: in many cases,
+    things are done differently than in "usual" Unix systems.
+    For example, there is no /bin directory (and therefore ubiquitous #!/bin/sh
+    scripts won't work). Instead, there is /system/bin.</p>
+
+    <p>I have a Samsung Galaxy Tab S (SM-T700 model) and I made it compile Busybox as follows:
+    <ul>
+    <li>"Rooted" the tablet (acquired root access). This step is device-specific.</li>
+    <li>Installed SuperSU application.</li>
+    <li>Installed the <a href="https://termux.com/">Termux</a> application -
+    it provides a small repository of essential tools: gcc-based toolchain,
+    git, ncurses, etc.</li>
+    <li>Ran its terminal, installed packages I needed, pulled Busybox git tree.</li>
+    <li>Created a /bin symlink to /system/bin, to make #!/bin/sh scripts work
+    (the build fails otherwise).</li>
+    <li>Now the usual "make defconfig", "make menuconfig", "make" work.</li>
+    </ul></p>
+
+    <p>Some parts won't compile (not all kernel headers are present, libc API
+    different or incomplete, etc). The maximal config which did compile
+    is now in the git tree, in configs/android_502_defconfig.
+    The toolchain provided by Termux is based on Android's Bionic libc
+    and Bionic has some design problems. An annoying one is that off_t is
+    32-bit, struct_stat::st_size is not off_t (this voilates standard
+    expectations), therefore CONFIG_LFS=y does not build, and CONFIG_LFS=n
+    builds with warnings (printf'ing st->st_size with wrong specifier).
+    </p>
+  </li>
+
   <li><b>24 March 2016 -- BusyBox 1.24.2 (stable)</b>
     <p><a href="http://busybox.net/downloads/busybox-1.24.2.tar.bz2">BusyBox 1.24.2</a>.
     (<a href="http://git.busybox.net/busybox/tree/?h=1_24_stable">git</a>,


More information about the busybox-cvs mailing list