Cyberithub

How to Install libtbb-dev package on Ubuntu 20.04 LTS (Focal Fossa)

Advertisements

In this article, I will take you through the steps to install libtbb-dev package on Ubuntu 20.04 LTS (Focal Fossa). Threading Building Blocks (TBB) is a C++ template library that helps us leverage multi-core processor performance without having to be a threading expert. It is developed by Intel for parallel programming on multi-core processors. Using this library, any complex computation can be broken down into multiple tasks that can run in parallel.

The library manages and schedules threads to execute these tasks. It represents a higher-level, task-based parallelism that abstracts platform details and threading mechanism for performance and scalability. This library can be installed through libtbb-dev package on Linux based systems. Here we will see the steps to install this library on Ubuntu based systems.

Advertisements

How to Install libtbb-dev package on Ubuntu 20.04 LTS (Focal Fossa)

How to Install libtbb-dev package on Ubuntu 20.04 LTS (Focal Fossa)

Also Read: How to Install SimulIDE on Ubuntu 20.04 LTS (Focal Fossa)

Step 1: Prerequisites

a) You should have a running Ubuntu 20.04 LTS Server.

Advertisements

b) You should have sudo or root access to run privileged commands.

c) You should have apt or apt-get utility available in your System.

Advertisements

 

Step 2: Update Your Server

First you need to update the System package cache with all the latest available updates from Ubuntu repo by using sudo apt update command as shown below.

cyberithub@ubuntu:~$ sudo apt update
Get:1 https://dl.google.com/linux/chrome/deb stable InRelease [1,811 B]
Get:2 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]
Hit:3 http://in.archive.ubuntu.com/ubuntu focal InRelease
Get:4 http://in.archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
Get:5 https://dl.google.com/linux/chrome/deb stable/main amd64 Packages [1,074 B]
Hit:6 https://download.docker.com/linux/ubuntu focal InRelease
Get:7 http://security.ubuntu.com/ubuntu focal-security/main amd64 DEP-11 Metadata [40.7 kB]
Get:8 http://in.archive.ubuntu.com/ubuntu focal-backports InRelease [108 kB]
Get:9 http://security.ubuntu.com/ubuntu focal-security/universe amd64 DEP-11 Metadata [77.3 kB]
Get:10 http://security.ubuntu.com/ubuntu focal-security/multiverse amd64 DEP-11 Metadata [2,464 B]
Get:11 http://in.archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages [2,072 kB]
Get:12 http://in.archive.ubuntu.com/ubuntu focal-updates/main i386 Packages [712 kB]
Get:13 http://in.archive.ubuntu.com/ubuntu focal-updates/main amd64 DEP-11 Metadata [278 kB]
Get:14 http://in.archive.ubuntu.com/ubuntu focal-updates/universe amd64 DEP-11 Metadata [391 kB]
Get:15 http://in.archive.ubuntu.com/ubuntu focal-updates/multiverse amd64 DEP-11 Metadata [940 B]
Get:16 http://in.archive.ubuntu.com/ubuntu focal-backports/main amd64 DEP-11 Metadata [7,996 B]
Get:17 http://in.archive.ubuntu.com/ubuntu focal-backports/universe amd64 DEP-11 Metadata [30.5 kB]
.......................................

 

Step 3: Install libtbb-dev

In the next step, install libtbb-dev package from default Ubuntu repo by using sudo apt install libtbb-dev command as shown below. This will download the library package along with all its dependencies.

Advertisements
cyberithub@ubuntu:~$ sudo apt install libtbb-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
libtbb2
Suggested packages:
libtbb-doc
The following NEW packages will be installed:
libtbb-dev libtbb2
0 upgraded, 2 newly installed, 0 to remove and 46 not upgraded.
Need to get 397 kB of archives.
After this operation, 2,483 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://in.archive.ubuntu.com/ubuntu focal/universe amd64 libtbb2 amd64 2020.1-2 [124 kB]
Get:2 http://in.archive.ubuntu.com/ubuntu focal/universe amd64 libtbb-dev amd64 2020.1-2 [273 kB]
Fetched 397 kB in 2s (204 kB/s)
Selecting previously unselected package libtbb2:amd64.
(Reading database ... 217645 files and directories currently installed.)
Preparing to unpack .../libtbb2_2020.1-2_amd64.deb ...
Unpacking libtbb2:amd64 (2020.1-2) ...
Selecting previously unselected package libtbb-dev:amd64.
Preparing to unpack .../libtbb-dev_2020.1-2_amd64.deb ...
Unpacking libtbb-dev:amd64 (2020.1-2) ...
Setting up libtbb2:amd64 (2020.1-2) ...
Setting up libtbb-dev:amd64 (2020.1-2) ...
Processing triggers for libc-bin (2.31-0ubuntu9.9) ...
......................................

 

Step 4: Verify the Package

After successful installation, you can verify all the installed files by using dpkg -L libtbb-dev command as shown below.

cyberithub@ubuntu:~$ dpkg -L libtbb-dev
/.
/usr
/usr/include
/usr/include/tbb
/usr/include/tbb/aggregator.h
/usr/include/tbb/aligned_space.h
/usr/include/tbb/atomic.h
/usr/include/tbb/blocked_range.h
/usr/include/tbb/blocked_range2d.h
/usr/include/tbb/blocked_range3d.h
/usr/include/tbb/blocked_rangeNd.h
/usr/include/tbb/cache_aligned_allocator.h
/usr/include/tbb/combinable.h
/usr/include/tbb/compat
/usr/include/tbb/compat/condition_variable
/usr/include/tbb/compat/ppl.h
/usr/include/tbb/compat/thread
/usr/include/tbb/compat/tuple
/usr/include/tbb/concurrent_hash_map.h
/usr/include/tbb/concurrent_lru_cache.h
/usr/include/tbb/concurrent_map.h
/usr/include/tbb/concurrent_priority_queue.h
......................................

Leave a Comment