How to Install and Uninstall g++ Package on Ubuntu 21.04 (Hirsute Hippo)

Last updated: November 22,2024

1. Install "g++" package

This is a short guide on how to install g++ on Ubuntu 21.04 (Hirsute Hippo)

$ sudo apt update $ sudo apt install g++

2. Uninstall "g++" package

Here is a brief guide to show you how to uninstall g++ on Ubuntu 21.04 (Hirsute Hippo):

$ sudo apt remove g++ $ sudo apt autoclean && sudo apt autoremove

3. Information about the g++ package on Ubuntu 21.04 (Hirsute Hippo)

Package: g++
Architecture: amd64
Version: 4:10.3.0-1ubuntu1
Priority: optional
Section: devel
Source: gcc-defaults (1.190ubuntu1)
Origin: Ubuntu
Maintainer: Ubuntu Developers
Original-Maintainer: Debian GCC Maintainers
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
Installed-Size: 16
Provides: c++-compiler, g++-x86-64-linux-gnu (= 4:10.3.0-1ubuntu1)
Depends: cpp (= 4:10.3.0-1ubuntu1), gcc (= 4:10.3.0-1ubuntu1), g++-10 (>= 10.3.0-1~), gcc-10 (>= 10.3.0-1~)
Suggests: g++-multilib
Filename: pool/main/g/gcc-defaults/g++_10.3.0-1ubuntu1_amd64.deb
Size: 1608
MD5sum: bb49c797040cf656ed72830a99c29f44
SHA1: 81952d846aa315b7af779edc04d36c79f9328e20
SHA256: 99359948f779674e88af5bd40812c687b94dafd326043b22ddb3668ab4b7666b
SHA512: 129c0a062dfddb9314b3036fd23507ebc84a234e6cc7ab40d604438aaa209c104551c861d93fb8a30ef611970375f2e5272089b8fa3416522d58b949a6602155
Description-en: GNU C++ compiler
This is the GNU C++ compiler, a fairly portable optimizing compiler for C++.
.
This is a dependency package providing the default GNU C++ compiler.
Description-md5: 4d44b18774ae5123b7c3f70d940cf655
Task: ubuntustudio-video, ubuntu-mate-core, ubuntu-mate-desktop
Build-Essential: yes