Kindle Native Development: Toolchain, FBInk, and LIPC
A jailbroken Kindle is an ARM Linux machine with root: koxtoolchain builds the cross-compilers, FBInk drives the e-ink framebuffer, LIPC exposes Amazon's system services, and Mesquito allows HTML/CSS/JS apps — Amazon's own Kindlet SDK having been discontinued in 2013.
A jailbroken Kindle is an ARM Linux machine with root access, and the community has assembled a full native development stack for it. Amazon's own developer offering — the KDK and its "Kindlets" Java SDK — was discontinued in 2013, so the community stack is not a workaround for a supported path. It is the only path. Toolchain and build: - koxtoolchain generates the cross-compilers. This step is not optional: Kindles run a heavily patched kernel against an old glibc, which defeats generic distribution toolchains. - kindle-sdk layers libraries and pkg-config on top, oriented around Meson. - Native GUI work is commonly done against GTK 2.0. - The same firmware-banded target split described in KOReader on Kindle: KUAL, kindlepw2, and kindlehf applies when choosing a toolchain target. Drawing to the screen: - FBInk is the practical entry point — a GPL-licensed library and command-line tool for printing text and images to an e-ink framebuffer, with handling for waveform modes and refresh control. It is used by KOReader itself and by other on-device tools. Driving `/dev/fb0` through raw ioctl calls is possible, but the ghosting and refresh-mode behaviour is what consumes the time, and that is precisely what FBInk encapsulates. System interfaces: - Input arrives through `/dev/input/event*`, and the stock interface is composited by the awesome window manager. - LIPC is Amazon's inter-process bus, scriptable from the shell via `lipc-set-prop`, exposing services including powerd (screensaver suppression, RTC wake, suspend deferral), wifid, and pmond. - Compiled binaries are placed under an `extensions/<app>/bin` path and launched from KUAL. Web-technology apps: - Mesquito is a framework for writing Kindle apps in HTML, CSS and JavaScript against an exposed `kindle` object providing filesystem reads, menu integration and gesture handling. Its engine capability is roughly that of Safari 5, making it a constrained but real target. Its existence sharpens a distinction worth keeping: the stock browser is the wrong runtime, which is not the same as web technology being the wrong language. Projects shipped on this stack include a terminal emulator, a Game Boy emulator, puzzle games, a Minecraft server, MicroPython, and full Debian and Alpine Linux chroots.