How To Install Wasm2c In Debian, Ubuntu, Arch, Kali And MacOS?

How To Install Wasm2c In Debian, Ubuntu, Arch, Kali And MacOS?

wasm2c

Convert a file from the WebAssembly binary format to a C source file and header.

Maintainer: Markus Koschany



Section: devel

Install wasm2c

  • Debian apt-get install wabt Click to copy
  • Ubuntu apt-get install wabt Click to copy
  • Arch Linux pacman -S wabt Click to copy
  • Kali Linux apt-get install wabt Click to copy
  • macOS brew install wabt Click to copy

Convert a file from the WebAssembly binary format to a C source file and header.

How to use wasm2c?

Below are few example commands for wasm2c that you can use in the terminal.

Convert a file to a C source file and header and display it to the console:
wasm2c file.wasmClick to copy
Write the output to a given file (file.h gets additionally generated):
wasm2c file.wasm -o file.cClick to copy
Installation of latest wasm2c command is available for Debian, Ubuntu, Arch, Kali and macOS. You can copy the command for your OS from above and paste it into your terminal. Once you run the command it will download the 2026 latest package from the repository and install it in your computer/server.