# Install gcc with Homebrew, apk, apt, dnf, Nix, pacman, scoop, zypper

GNU compiler collection. Version 16.1.0 via Homebrew; verified 2026-07-03.

## Install

```sh
sudo av install brew:gcc
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install gcc
```

  Evidence: local Homebrew formula metadata

### Linux

- apk (92%):

```sh
sudo apk add g++
```

  Evidence: Alpine Linux edge package indexes: g++ from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install gcc
```

  Evidence: Debian stable package indexes: gcc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- dnf (92%):

```sh
sudo dnf install cpp
```

  Evidence: Fedora Rawhide package metadata: cpp from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#gcc
```

  Evidence: nixpkgs package indexes: gcc from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix

- pacman (92%):

```sh
sudo pacman -S gcc
```

  Evidence: Arch Linux sync databases: gcc from https://geo.mirror.pkgbuild.com/core/os/x86_64/core.db.tar.gz

- zypper (92%):

```sh
sudo zypper install cpp
```

  Evidence: openSUSE Tumbleweed package metadata: cpp from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst

### Windows

- Scoop (92%):

```sh
scoop install main/gcc
```

  Evidence: Scoop official bucket manifest trees: bucket/gcc.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1

## Package facts

- **Package key:** brew:gcc
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/gcc>
- **Version:** 16.1.0
- **Source summary:** GNU compiler collection
- **Homepage:** <https://gcc.gnu.org/>
- **Repository:** <https://gcc.gnu.org/git/gcc.git>
- **Upstream docs:** <https://gcc.gnu.org/onlinedocs>
- **License:** GPL-3.0-or-later WITH GCC-exception-3.1
- **Source archive:** <https://ftpmirror.gnu.org/gnu/gcc/gcc-16.1.0/gcc-16.1.0.tar.xz>
- **Last updated:** 2026-07-03T22:53:05-04:00
- **Generated:** 2026-07-09T07:20:21+00:00

## Executables

- aarch64-unknown-linux-gnu-c++-15 (cli)
- aarch64-unknown-linux-gnu-g++-15 (cli)
- aarch64-unknown-linux-gnu-gcc-15 (cli)
- aarch64-unknown-linux-gnu-gcc-ar-15 (cli)
- aarch64-unknown-linux-gnu-gcc-nm-15 (cli)
- aarch64-unknown-linux-gnu-gcc-ranlib-15 (cli)
- aarch64-unknown-linux-gnu-gfortran-15 (cli)
- aarch64-unknown-linux-gnu-gm2-15 (cli)
- c++-15 (cli)
- cpp-15 (cli)
- g++-15 (cli)
- gcc-15 (cli)
- gcc-ar-15 (cli)
- gcc-nm-15 (cli)
- gcc-ranlib-15 (cli)
- gcov-15 (cli)
- gcov-dump-15 (cli)
- gcov-tool-15 (cli)
- gfortran (cli)
- gfortran-15 (cli)
- gm2 (cli)
- gm2-15 (cli)
- lto-dump-15 (cli)
- aarch64-unknown-linux-gnu-c++-15 (alias)
- aarch64-unknown-linux-gnu-g++-15 (alias)
- aarch64-unknown-linux-gnu-gcc-15 (alias)
- aarch64-unknown-linux-gnu-gcc-ar-15 (alias)
- aarch64-unknown-linux-gnu-gcc-nm-15 (alias)
- aarch64-unknown-linux-gnu-gcc-ranlib-15 (alias)
- aarch64-unknown-linux-gnu-gfortran-15 (alias)
- aarch64-unknown-linux-gnu-gm2-15 (alias)
- c++-15 (alias)
- cpp-15 (alias)
- g++-15 (alias)
- gcc-15 (alias)
- gcc-ar-15 (alias)
- gcc-nm-15 (alias)
- gcc-ranlib-15 (alias)
- gcov-15 (alias)
- gcov-dump-15 (alias)
- gcov-tool-15 (alias)
- gfortran (alias)
- gfortran-15 (alias)
- gm2 (alias)
- gm2-15 (alias)
- lto-dump-15 (alias)

## Dependencies

- gmp
- isl
- libmpc
- mpfr
- zstd

## Build dependencies

- make

## Install behavior

- Post-install hook: defined
- Bottle: available on arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sequoia, sonoma, tahoe, x86_64_linux

## Freshness

- Page generated: 2026-07-09
- Package-manager version: 16.1.0
- Package-manager updated: 2026-07-03
- Local data: ok
- Upstream repository: https://gcc.gnu.org/
- info: Release/tag comparison is only available for GitHub repositories.
## Project history and usage

GCC, the GNU Compiler Collection, is the GNU project's long-running compiler suite and one of the central packages in free-software toolchains. It is both a user-facing compiler driver family and a distribution-building dependency for C, C++, Fortran, Objective-C, Ada, Go-related runtime pieces, and other GCC-supported languages and targets.

### Project history

The official release timeline lists GCC 0.9 as the first beta release in March 1987 and GCC 1.0 in May 1987. The project later absorbed the EGCS line: the timeline records EGCS 1.0 in December 1997, EGCS 1.1.x through March 1999, and GCC 2.95 in July 1999, the release family generally associated with the reunited GCC project.

### Adoption history

The GCC mission statement frames the project as part of GNU and explicitly targets the GNU system, GNU/Linux, multiple architectures, and diverse platforms. This open-development and multi-target mission is why GCC became a default compiler in many Unix-like operating systems and remains a package-manager anchor: large parts of a distribution are either built by it, bootstrap it, or carry compatibility logic for it.

### How it is used

Package users normally invoke compiler drivers such as gcc, g++, cpp, gfortran, gcov, and lto-dump, while packagers care about release branches, source tarballs, bootstrapping requirements, generated files in Git checkouts, and runtime-library licensing. The official Git page documents cloning from https://gcc.gnu.org/git/gcc.git, release branches under releases/gcc-N, and release tags such as releases/gcc-X.Y.0.

### Why package nerds care

GCC is package-manager infrastructure, not just another package. It drives ABI compatibility, bootstrap chains, language standard defaults, libstdc++ behavior, cross-compilation targets, build flags, sanitizer support, and the difference between a distribution that can rebuild itself and one that cannot.

### Timeline

- 1987: GCC 0.9 first beta release.
- 1987: GCC 1.0 released.
- 1997: EGCS 1.0 released as a parallel compiler line.
- 1999: GCC 2.95 released after the EGCS era.
- 2001: GCC 3.0 released.
- 2005: GCC 4.0.0 released.
- 2015: GCC 5.1 released under the modern major-version release scheme.
- 2025: GCC 15.1 released.
- 2026: GCC 16.1 released.

### Related projects

- GCC is tied to the GNU Project, GNU/Linux distributions, libstdc++, binutils, GDB, the GNU build toolchain, and competing or complementary compilers such as Clang/LLVM. Its own official Git documentation also treats release branches and tags as first-class package artifacts.

### Sources

- <https://gcc.gnu.org/>
- <https://gcc.gnu.org/gccmission.html>
- <https://gcc.gnu.org/git.html>
- <https://gcc.gnu.org/onlinedocs/>
- <https://gcc.gnu.org/releases.html>


## Security Notes

compiler and toolchain runtime.

- **Geiger risk:** yellow / high
- compiler and toolchain runtime

## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** gcc
- **Aliases:** gcc@16, gfortran
- **Version Scheme:** 0
- **Revision:** 0
- **Head Version:** HEAD
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** head, stable

## Other Package-Manager Records

- Debian apt - gcc - 4:14.2.0-1: normalized package name match | Debian stable package indexes: gcc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | GNU C compiler
- Nix - gcc: normalized package name match | nixpkgs package indexes: gcc from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix
- Ubuntu apt - gcc - 4:13.2.0-7ubuntu1: normalized package name match | Ubuntu 24.04 LTS package indexes: gcc from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | GNU C compiler
- apk - g++ - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: g++ from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | GNU C++ standard library and compiler | https://gcc.gnu.org
- apk - gcc - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: gcc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | The GNU Compiler Collection | https://gcc.gnu.org
- apk - gcc-doc - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: gcc-doc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | The GNU Compiler Collection (documentation) | https://gcc.gnu.org
- apk - gcc-gdb - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: gcc-gdb from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | The GNU Compiler Collection (gdb printers) | https://gcc.gnu.org
- apk - gcc-gdc - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: gcc-gdc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | GCC-based D language compiler | https://gcc.gnu.org
- apk - gcc-gnat - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: gcc-gnat from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Ada support for GCC | https://gcc.gnu.org
- apk - gcc-go - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: gcc-go from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | GCC Go frontend (intended for bootstrapping community/go) | https://gcc.gnu.org
- apk - gcc-objc - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: gcc-objc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | GNU Objective-C | https://gcc.gnu.org
- apk - gfortran - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: gfortran from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | GNU Fortran Compiler | https://gcc.gnu.org
- apk - libatomic - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: libatomic from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | GCC Atomic library | https://gcc.gnu.org
- apk - libgcc - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: libgcc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | GNU C compiler runtime libraries | https://gcc.gnu.org
- apk - libgcc-static - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: libgcc-static from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | GNU C compiler runtime libraries | https://gcc.gnu.org
- apk - libgccjit - 15.2.0-r5: normalized package name match | Alpine Linux edge package indexes: libgccjit from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | GCC JIT Library | https://gcc.gnu.org


## Related links

- [Secret-risk packages](https://www.automicvault.com/pkg/secret-risk-packages/) - Has protected-tool coverage, approval-gate, or non-low Geiger security signals.
- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Developer build packages](https://www.automicvault.com/pkg/developer-build-tools/) - Matched build, compiler, generator, or developer workflow metadata.
- [Language runtime packages](https://www.automicvault.com/pkg/language-runtime-packages/) - Matched language runtime, compiler, or interpreter metadata.
- [zstd](https://www.automicvault.com/pkg/brew/zstd/) - Runtime dependency declared by Homebrew.
- [make](https://www.automicvault.com/pkg/brew/make/) - Build dependency declared by Homebrew.
- [adios2](https://www.automicvault.com/pkg/brew/adios2/) - Popular package that depends on this formula.
- [aider](https://www.automicvault.com/pkg/brew/aider/) - Popular package that depends on this formula.
- [calceph](https://www.automicvault.com/pkg/brew/calceph/) - Popular package that depends on this formula.
- [cgns](https://www.automicvault.com/pkg/brew/cgns/) - Popular package that depends on this formula.
- [cp2k](https://www.automicvault.com/pkg/brew/cp2k/) - Popular package that depends on this formula.
- [damask-grid](https://www.automicvault.com/pkg/brew/damask-grid/) - Popular package that depends on this formula.
- [gcc@10](https://www.automicvault.com/pkg/brew/gcc-10/) - Package name indicates the same formula family.
- [gcc@11](https://www.automicvault.com/pkg/brew/gcc-11/) - Package name indicates the same formula family.
- [gcc@12](https://www.automicvault.com/pkg/brew/gcc-12/) - Package name indicates the same formula family.
- [gcc@13](https://www.automicvault.com/pkg/brew/gcc-13/) - Package name indicates the same formula family.
- [gcc@14](https://www.automicvault.com/pkg/brew/gcc-14/) - Package name indicates the same formula family.
- [gcc@15](https://www.automicvault.com/pkg/brew/gcc-15/) - Package name indicates the same formula family.
- [gcc@9](https://www.automicvault.com/pkg/brew/gcc-9/) - Package name indicates the same formula family.
- [gnucobol](https://www.automicvault.com/pkg/brew/gnucobol/) - Shares av.db curated category or tags: cli, compiler, compilers, gnu, language-runtime.
- [fpc](https://www.automicvault.com/pkg/brew/fpc/) - Shares av.db curated category or tags: cli, compiler, compilers, language-runtime.
- [futhark](https://www.automicvault.com/pkg/brew/futhark/) - Shares av.db curated category or tags: cli, compiler, compilers, language-runtime.
- [ispc](https://www.automicvault.com/pkg/brew/ispc/) - Shares av.db curated category or tags: cli, compiler, compilers, language-runtime.
- [gcc](https://www.automicvault.com/pkg/cargo/gcc/) - Same normalized package name exists in another local package ecosystem.

## Combined YAML source

View the package source record on GitHub. [combined/gcc.yml](https://github.com/automic-vault/db/blob/main/combined/gcc.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
