How to Install and Uninstall gcc-7 Package on Ubuntu 21.04 (Hirsute Hippo)

Last updated: December 24,2024

1. Install "gcc-7" package

Please follow the steps below to install gcc-7 on Ubuntu 21.04 (Hirsute Hippo)

$ sudo apt update $ sudo apt install gcc-7

2. Uninstall "gcc-7" package

This is a short guide on how to uninstall gcc-7 on Ubuntu 21.04 (Hirsute Hippo):

$ sudo apt remove gcc-7 $ sudo apt autoclean && sudo apt autoremove

3. Information about the gcc-7 package on Ubuntu 21.04 (Hirsute Hippo)

Package: gcc-7
Architecture: amd64
Version: 7.5.0-6ubuntu4
Priority: optional
Section: universe/devel
Origin: Ubuntu
Maintainer: Ubuntu Core developers
Original-Maintainer: Debian GCC Maintainers
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
Installed-Size: 27421
Provides: c-compiler
Depends: cpp-7 (= 7.5.0-6ubuntu4), gcc-7-base (= 7.5.0-6ubuntu4), libcc1-0 (>= 7.5.0-6ubuntu4), binutils (>= 2.35.1), libgcc-7-dev (= 7.5.0-6ubuntu4), libc6 (>= 2.15), libgcc-s1 (>= 3.0), libgmp10 (>= 2:5.0.1~), libisl23 (>= 0.15), libmpc3 (>= 1.1.0), libmpfr6 (>= 3.1.3), libstdc++6 (>= 5), zlib1g (>= 1:1.1.4)
Recommends: libc6-dev (>= 2.13-0ubuntu6)
Suggests: gcc-7-multilib, gcc-7-doc (>= 7), gcc-7-locales (>= 7)
Replaces: cpp-7 (<< 7.1.1-8), gccgo-7 (<< 7.5.0-6ubuntu4)
Filename: pool/universe/g/gcc-7/gcc-7_7.5.0-6ubuntu4_amd64.deb
Size: 9407624
MD5sum: 79390beac81fabab592609b0d3c5e54e
SHA1: 046de8d953cc37626681782788f1dcb6f8d1bb53
SHA256: 2210836946d03d752351b7c7a38768d17712e7d06c91c6b7e1b1eeb48557882d
SHA512: 27effb27db9f5dff8967b4df11ed336f8bf41268d4aa8477dd630ce62aec8b8982ff3958f7039335355200a5e3f8ebeb49cc54e3ebe340a37f57a351dde71062
Homepage: http://gcc.gnu.org/
Description-en: GNU C compiler
This is the GNU C compiler, a fairly portable optimizing compiler for C.
Description-md5: 394374e688b1afb3af5f419895d29698