How To Install wabt on Debian 10

Learn how to install wabt on Debian 10 with this tutorial. wabt is WebAssembly Binary Toolkit

Introduction

In this tutorial we learn how to install wabt on Debian 10.

What is wabt

wabt is:

WABT (pronounced: “wabbit”) is a suite of tools for WebAssembly, including:

  • wat2wasm: translate from WebAssembly text format to the WebAssembly binary format
  • wasm2wat: the inverse of wat2wasm, translate from the binary format back to the text format (also known as a .wat)
  • wasm-objdump: print information about a wasm binary. Similar to objdump.
  • wasm-interp: decode and run a WebAssembly binary file using a stack-based interpreter
  • wat-desugar: parse .wat text form as supported by the spec interpreter (s-expressions, flat syntax, or mixed) and print “canonical” flat format
  • wasm2c: convert a WebAssembly binary file to a C source and header

These tools are intended for use in (or for development of) toolchains or other systems that want to manipulate WebAssembly files. Unlike the WebAssembly spec interpreter (which is written to be as simple, declarative and “speccy” as possible), they are written in C/C++ and designed for easier integration into other systems. Unlike Binaryen these tools do not aim to provide an optimization platform or a higher-level compiler target; instead they aim for full fidelity and compliance with the spec (e.g. 1:1 round-trips with no changes to instructions).

There are three methods to install wabt on Debian 10. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install wabt Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install wabt using apt-get by running the following command:

sudo apt-get -y install wabt

Install wabt Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install wabt using apt by running the following command:

sudo apt -y install wabt

Install wabt Using aptitude

If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Debian. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install wabt using aptitude by running the following command:

sudo aptitude -y install wabt

How To Uninstall wabt on Debian 10

To uninstall only the wabt package we can use the following command:

sudo apt-get remove wabt

Uninstall wabt And Its Dependencies

To uninstall wabt and its dependencies that are no longer needed by Debian 10, we can use the command below:

sudo apt-get -y autoremove wabt

Remove wabt Configurations and Data

To remove wabt configuration and data from Debian 10 we can use the following command:

sudo apt-get -y purge wabt

Remove wabt configuration, data, and all of its dependencies

We can use the following command to remove wabt configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge wabt

Dependencies

wabt have the following dependencies:

References

Summary

In this tutorial we learn how to install wabt package on Debian 10 using different package management tools: apt, apt-get and aptitude.