How To Install libcpuinfo-dev on Kali Linux

In this tutorial we learn how to install libcpuinfo-dev on Kali Linux. libcpuinfo-dev is CPU INFOrmation library (header file)

Introduction

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

What is libcpuinfo-dev

libcpuinfo-dev is:

cpuinfo is a library to detect essential for performance optimization information about host CPU.

Features

  • Cross-platform availability:
    • Linux, Windows, macOS, Android, and iOS operating systems
    • x86, x86-64, ARM, and ARM64 architectures
  • Modern C/C++ interface
    • Thread-safe
    • No memory allocation after initialization
    • No exceptions thrown
  • Detection of supported instruction sets, up to AVX512 (x86) and ARMv8.3 extensions
  • Detection of SoC and core information:
    • Processor (SoC) name
    • Integrated GPU name (Android/iOS only)
    • Vendor, microarchitecture, and ID (MIDR on ARM, CPUID leaf 1 EAX value on x86) for each CPU core
  • Detection of cache information:
    • Cache type (instruction/data/unified), size and line size
    • Cache associativity
    • Cores and logical processors (hyper-threads) sharing the cache
  • Detection of topology information (relative between logical processors, cores, and processor packages)
  • Well-tested production-quality code:
    • 60+ mock tests based on data from real devices
    • Includes work-arounds for common bugs in hardware and OS kernels
    • Supports systems with heterogenous cores, such as big.LITTLE and Max.Med.Min
  • Permissive open-source license (Simplified BSD)

This package ships with the header file.

There are three methods to install libcpuinfo-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 libcpuinfo-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 libcpuinfo-dev using apt-get by running the following command:

sudo apt-get -y install libcpuinfo-dev

Install libcpuinfo-dev Using apt

Update apt database with apt using the following command.

sudo apt update

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

sudo apt -y install libcpuinfo-dev

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

sudo aptitude -y install libcpuinfo-dev

How To Uninstall libcpuinfo-dev on Kali Linux

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

sudo apt-get remove libcpuinfo-dev

Uninstall libcpuinfo-dev And Its Dependencies

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

sudo apt-get -y autoremove libcpuinfo-dev

Remove libcpuinfo-dev Configurations and Data

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

sudo apt-get -y purge libcpuinfo-dev

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

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

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

Dependencies

libcpuinfo-dev have the following dependencies:

References

Summary

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