How To Install libkdtree++-dev on Kali Linux

In this tutorial we learn how to install libkdtree++-dev on Kali Linux. libkdtree++-dev is C++ template container implementation of kd-tree sorting

Introduction

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

What is libkdtree++-dev

libkdtree++-dev is:

libkdtree++ is a C++ template container implementation of k-dimensional space sorting, using a kd-tree. It:

  • supports an unlimited number of dimensions (in theory)
  • can store any data structure, provided the data structure provides operator[0 - k-1] to access the individual dimensional components (arrays, std::vector already do) and a std::less implementation for the type of dimensional components
  • has support for custom allocators
  • implements iterators
  • provides standard find as well as range queries
  • has amortised O(lg n) time (O(n lg n) worst case) on most operations (insert/erase/find optimised) and worst-case O(n) space
  • provides a means to rebalance and thus optimise the tree
  • exists in its own namespace
  • uses STL coding style, basing a lot of the code on stl_tree.h

libkdtree++ only exists as a -dev package as it’s only a bunch of C++ header files. Therefore, no static or shared library is necessary, allowing for ultimate flexibility.

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

sudo apt-get -y install libkdtree++-dev

Install libkdtree++-dev Using apt

Update apt database with apt using the following command.

sudo apt update

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

sudo apt -y install libkdtree++-dev

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

sudo aptitude -y install libkdtree++-dev

How To Uninstall libkdtree++-dev on Kali Linux

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

sudo apt-get remove libkdtree++-dev

Uninstall libkdtree++-dev And Its Dependencies

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

sudo apt-get -y autoremove libkdtree++-dev

Remove libkdtree++-dev Configurations and Data

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

sudo apt-get -y purge libkdtree++-dev

Remove libkdtree++-dev configuration, data, and all of its dependencies

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

sudo apt-get -y autoremove --purge libkdtree++-dev

Dependencies

libkdtree++-dev have the following dependencies:

References

Summary

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