How To Install libboost-chrono-dev on Kali Linux

In this tutorial we learn how to install libboost-chrono-dev on Kali Linux. libboost-chrono-dev is C++ representation of time duration, time point, and clocks (default version)

Introduction

In this tutorial we learn how to install libboost-chrono-dev on Kali Linux.

What is libboost-chrono-dev

libboost-chrono-dev is:

This package forms part of the Boost C++ Libraries collection.

The Boost.Chrono library provides:

  • A means to represent time durations: managed by the generic duration class . Examples of time durations include days, minutes, seconds and nanoseconds, which can be represented with a fixed number of clock ticks per unit. All of these units of time duration are united with a generic interface by the duration facility.
  • A type for representing points in time: time_point. A time_point represents an epoch plus or minus a duration. The library leaves epochs unspecified. A time_point is associated with a clock.
  • Several clocks, some of which may not be available on a particular platform: system_clock, steady_clock and high_resolution_clock. A clock is a pairing of a time_point and duration, and a function which returns a time_point representing now.

To make the timing facilities more generally useful, Boost.Chrono provides a number of clocks that are thin wrappers around the operating system’s time APIs, thereby allowing the extraction of wall clock time, user CPU time, system CPU time spent by the process:

  • process_real_cpu_clock, captures wall clock CPU time spent by the current process.
  • process_user_cpu_clock, captures user-CPU time spent by the current process.
  • process_system_cpu_clock, captures system-CPU time spent by the current process.
  • A tuple-like class process_cpu_clock, that captures real, user-CPU, and system-CPU process times together.
  • A thread_clock thread steady clock giving the time spent by the current thread (when supported by a platform).

Lastly, Boost.Chrono includes typeof registration for duration and time_point to permit using emulated auto with C++03 compilers.

This package is a dependency package, which depends on Debian’s default Boost version (currently 1.74).

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

Install libboost-chrono-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 libboost-chrono-dev using apt-get by running the following command:

sudo apt-get -y install libboost-chrono-dev

Install libboost-chrono-dev Using apt

Update apt database with apt using the following command.

sudo apt update

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

sudo apt -y install libboost-chrono-dev

Install libboost-chrono-dev Using aptitude

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

sudo aptitude update

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

sudo aptitude -y install libboost-chrono-dev

How To Uninstall libboost-chrono-dev on Kali Linux

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

sudo apt-get remove libboost-chrono-dev

Uninstall libboost-chrono-dev And Its Dependencies

To uninstall libboost-chrono-dev and its dependencies that are no longer needed by Kali Linux, we can use the command below:

sudo apt-get -y autoremove libboost-chrono-dev

Remove libboost-chrono-dev Configurations and Data

To remove libboost-chrono-dev configuration and data from Kali Linux we can use the following command:

sudo apt-get -y purge libboost-chrono-dev

Remove libboost-chrono-dev configuration, data, and all of its dependencies

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

sudo apt-get -y autoremove --purge libboost-chrono-dev

Dependencies

libboost-chrono-dev have the following dependencies:

References

Summary

In this tutorial we learn how to install libboost-chrono-dev package on Kali Linux using different package management tools: apt, apt-get and aptitude.