BusyBox compiled to WebAssembly using Emscripten. This repo contains build scripts without being a full fork of BusyBox, making version upgrades easier.
Current versions: BusyBox 1.37.0, Emscripten 4.x
Pre-built binaries are available on the Releases page:
busybox-linux-x86_64- Native Linux binarybusybox.js/busybox.wasm- WebAssembly build
Requires Emscripten SDK for WASM builds.
The WASM build is emitted as an ES module (MODULARIZE + EXPORT_ES6) so it can be used directly in Deno.
The helper in deno/busybox_runner.ts loads busybox.js/busybox.wasm and exposes a simple run() API.
busybox.js/busybox.wasm are expected to live next to the runner in releases or your build output.
# native version
make build/native/busybox
# wasm version
make build/wasm/busybox_unstripped.jsThis repo includes two custom BusyBox applets:
-
nanozip - miniz-based imitation of
ziputility:busybox nanozip [-r] [[-x EXCLUDED_PATH] ...] OUTPUT_NAME.zip INPUT_PATH [...] -
diff3 - OpenBSD-based implementation of diff3:
busybox diff3 [-exEX3] /tmp/d3a.?????????? /tmp/d3b.?????????? file1 file2 file3
The em-shell.c, em-shell.h, em-shell.js files are based on the excellent work by Todd Fleming:
These have been updated for modern Emscripten (4.x) compatibility.