hope2333.github.io / wiki

build


Build opencode-termux

Make Targets

make all VER=1.18.27 PKG=both        # Build all families for a version
make batch VERS='1.18.15 1.18.27' PKG=deb  # Build range
make selfcheck                        # Validate setup

Family-specific targets

make family-glibc VER=1.18.27        # Glibc line only
make family-native VER=1.18.27       # Native line only
make family-compressed VER=1.18.27   # Compressed (UPX) only

Batch scripts

Transplant Pipeline (Native)

The native line uses a transplant-revive pipeline:

  1. Extract: Base Bun ELF from official Android build
  2. Detect: Section format (auto per Bun version)
  3. Convert: Module graph insertion
  4. Patch: BUN_COMPILED.size + offsets
  5. Assemble: Final ELF layout
  6. Revive: Runtime resurrection surgery
  7. Verify: Self-test run

After transplant, a seccomp-harden step adds the SIGSYS crhandler shim.

Build Requirements