How To Install libnanomsg-dev on Debian 9

In this tutorial we learn how to install libnanomsg-dev on Debian 9. libnanomsg-dev is nanomsg development files

Introduction

In this tutorial we learn how to install libnanomsg-dev on Debian 9.

What is libnanomsg-dev

libnanomsg-dev is:

nanomsg is a socket library that provides several common communication patterns. It aims to make the networking layer fast, scalable, and easy to use. Implemented in C, it works on a wide range of operating systems with no further dependencies.

The communication patterns, also called “scalability protocols”, are basic blocks for building distributed systems. By combining them you can create a vast array of distributed applications. The following scalability protocols are currently available:

PAIR - simple one-to-one communication
BUS - simple many-to-many communication
REQREP - allows one to build clusters of stateless services
         to process user requests
PUBSUB - distributes messages to large sets of interested subscribers
PIPELINE - aggregates messages from multiple sources and
           load balances them among many destinations
SURVEY - allows one to query state of multiple applications in a single go

This package contains the development files for nanomsg.

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

Install libnanomsg-dev Using apt-get

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

sudo apt-get update

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

sudo apt-get -y install libnanomsg-dev

Install libnanomsg-dev Using apt

Update apt database with apt using the following command.

sudo apt update

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

sudo apt -y install libnanomsg-dev

Install libnanomsg-dev 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 libnanomsg-dev using aptitude by running the following command:

sudo aptitude -y install libnanomsg-dev

How To Uninstall libnanomsg-dev on Debian 9

To uninstall only the libnanomsg-dev package we can use the following command:

sudo apt-get remove libnanomsg-dev

Uninstall libnanomsg-dev And Its Dependencies

To uninstall libnanomsg-dev and its dependencies that are no longer needed by Debian 9, we can use the command below:

sudo apt-get -y autoremove libnanomsg-dev

Remove libnanomsg-dev Configurations and Data

To remove libnanomsg-dev configuration and data from Debian 9 we can use the following command:

sudo apt-get -y purge libnanomsg-dev

Remove libnanomsg-dev configuration, data, and all of its dependencies

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

sudo apt-get -y autoremove --purge libnanomsg-dev

Dependencies

libnanomsg-dev have the following dependencies:

References

Summary

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