I'm still on Ubuntu 22.04 LTS but needed g++14. The sudo apt-get gcc-14 did not work for me, as it installed clang++14 for some reason (perhaps a misconfiguration on my part). What did work for me was following the instructions I found at https://www.dedicatedcore.com/blog/install-gcc-compiler-ubuntu/

The steps I took:

sudo apt install build-essential
sudo apt install libmpfr-dev libgmp3-dev libmpc-dev -y
wget https://ftp.gnu.org/gnu/gcc/gcc-14.1.0/gcc-14.1.0.tar.gz
tar -xf gcc-14.1.0.tar.gz
cd gcc-14.1.0
./configure -v --build=$(uname -m)-linux-gnu --host=$(uname -m)-linux-gnu --target=$(uname -m)-linux-gnu --prefix=/usr/local/gcc-14.1.0 --enable-checking=release --enable-languages=c,c++ --disable-multilib --program-suffix=-14.1.0
make
sudo make install

And if you would like to make it the default:

sudo update-alternatives --install /usr/bin/g++ g++ /usr/local/gcc-14.1.0/bin/g++-14.1.0 14
sudo update-alternatives --install /usr/bin/gcc gcc /usr/local/gcc-14.1.0/bin/gcc-14.1.0 14

After that, g++ showed I was running version 14.1.0. I was then able to compile my project that included some c++20/23 features that were not in the previous versions of g++ (chrono/format).

Answer from John Jones on askubuntu.com
🌐
GNU
gcc.gnu.org › gcc-14
GCC 14 Release Series - GNU Project
May 23, 2025 - The GCC developers are pleased to announce the release of GCC 14.3.
Top answer
1 of 5
20

I'm still on Ubuntu 22.04 LTS but needed g++14. The sudo apt-get gcc-14 did not work for me, as it installed clang++14 for some reason (perhaps a misconfiguration on my part). What did work for me was following the instructions I found at https://www.dedicatedcore.com/blog/install-gcc-compiler-ubuntu/

The steps I took:

sudo apt install build-essential
sudo apt install libmpfr-dev libgmp3-dev libmpc-dev -y
wget https://ftp.gnu.org/gnu/gcc/gcc-14.1.0/gcc-14.1.0.tar.gz
tar -xf gcc-14.1.0.tar.gz
cd gcc-14.1.0
./configure -v --build=$(uname -m)-linux-gnu --host=$(uname -m)-linux-gnu --target=$(uname -m)-linux-gnu --prefix=/usr/local/gcc-14.1.0 --enable-checking=release --enable-languages=c,c++ --disable-multilib --program-suffix=-14.1.0
make
sudo make install

And if you would like to make it the default:

sudo update-alternatives --install /usr/bin/g++ g++ /usr/local/gcc-14.1.0/bin/g++-14.1.0 14
sudo update-alternatives --install /usr/bin/gcc gcc /usr/local/gcc-14.1.0/bin/gcc-14.1.0 14

After that, g++ showed I was running version 14.1.0. I was then able to compile my project that included some c++20/23 features that were not in the previous versions of g++ (chrono/format).

2 of 5
16

GCC-14 (and G++-14) is available in the Universe repository for Ubuntu 24.04, as evident in the Ubuntu Package archive.

It is equally evident that this package is not available for Ubuntu 22.04, so installing this on 22.04 will require some third-party interference, or you have to compile it yourself.

See here on how to enable the Universe repositories.

Discussions

GCC 14 twice as slow as GCC 13?
Do you see the difference when compiling using clang with libstdc++ (and comparing libstdc++ 13 and 14)? More on reddit.com
🌐 r/cpp
37
76
April 29, 2024
How important are gcc versions?
Typically, you should just use the latest version available in your distro. The only reason to use an older version is when you're working on a project that's effectively stuck on that version due to weird quirks or some other constraint that explicitly ties you to a certain version. You can also just download the latest version if your distro is lagging behind. As for changes, you can check on the website. Here's GCC 14's change summary , for example. In general, when the N in GCC N changes, that's a big, destabilizing change. Those tend to introduce a large amount of changes and/or a large change to a major component. If the decimal increments, then that introduces fixes and minor improvements that won't cause any potential conflicts when updating. More on reddit.com
🌐 r/C_Programming
32
17
May 13, 2024
GCC 14 on Fedora 42
So, I found this page which mentions, correctly, that package gcc-14 exists, and I installed it. Now I want this GCC to be the default one. The page suggests this: Using the alternatives system: sudo alternatives --config gcc This displays a menu allowing you to select the default gcc command. More on discussion.fedoraproject.org
🌐 discussion.fedoraproject.org
2
0
May 22, 2025
GCC version 14 coming soon – and will drop Itanium support
I saw the picture of the ship and immediately thought, that must be an article in The Register... Removal of Itanium from gcc is long expected. I actually don't think I've ever seen an Itanium based system ever. More on reddit.com
🌐 r/programming
111
401
April 12, 2024
🌐
Red Hat
developers.redhat.com › articles › 2024 › 05 › 15 › new-c-features-gcc-14
New C++ features in GCC 14 | Red Hat Developer
December 12, 2024 - Discover new features and enhancements in the C++ front end in GCC 14, the next major version of the GNU Compiler Collection.
🌐
Reddit
reddit.com › r/cpp › gcc 14 twice as slow as gcc 13?
r/cpp on Reddit: GCC 14 twice as slow as GCC 13?
April 29, 2024 -

Ubuntu 24.04 has GCC 14, and on our CI, it takes twice as long to compile the same Boost tests as GCC 13, other things being equal. At first we thought there was something wrong with Ubuntu's GCC 14 (as it's not officially out yet), but a freshly compiled GCC 14 from source seems to give the same result.

Anyone else seen this, or know something about it? 2x slowdown seems like a noticeable regression.

🌐
SourceForge
sourceforge.net › projects › gcc-win64
gcc-win64 download | SourceForge.net
Download gcc-win64 for free. x64 build of GCC for Windows. x64 C/C++ compiler for Windows using (unofficial build): - gmp - mpfr - mpc - isl - cloog - mingw-w64 - gcc - seh You need at least core2 command set support to run this application. Note that every version with bundled gdb needs at least Windows 7.
🌐
GNU
gcc.gnu.org › gcc-14 › changes.html
GCC 14 Release Series — Changes, New Features, and Fixes - GNU Project
April 30, 2026 - C++ module scanning for named modules is now available, based on the format described in P1689R5, Format for describing dependencies of source files. The -fdeps-format=, -fdeps-file=, and -fdeps-target= flags may be used to generate dependency information. In GCC 14 p1689r5 is the only valid ...
Find elsewhere
🌐
DevDocs
devdocs.io › gcc
DevDocs — GCC 14 documentation
GCC 14.2.0 API documentation with instant search, offline support, keyboard shortcuts, mobile version, and more.
🌐
Arch Linux
aur.archlinux.org › packages › gcc14
AUR (en) - gcc14
December 28, 2025 - since I know @imrehg, i'm just gonna give up and use his packages. Did you bounce back to gcc15 to get this to compile? ... Compiled and uploaded the latest 14.3.1+r516+g5998566829ee-1 version to https://aur-imreh-net.ipns.dweb.link/gcc14/ in case it's useful.
🌐
GitHub
github.com › iains › gcc-14-branch
GitHub - iains/gcc-14-branch: GCC 14 for Darwin with experimental Arm64 support. Current release 14.2-darwin-r2 [October 2024] · GitHub
GCC 14 for Darwin with experimental Arm64 support. Current release 14.2-darwin-r2 [October 2024] - iains/gcc-14-branch
Starred by 18 users
Forked by 6 users
Languages   C++ 32.3% | C 30.9% | Ada 12.1% | D 6.6% | Go 6.3% | GCC Machine Description 3.6%
🌐
SUSE
documentation.suse.com › sbp › devel-tools › html › SBP-GCC-14 › index.html
Advanced Optimization and New Capabilities of GCC 14 | SUSE Linux Enterprise Server 15 SP6
February 16, 2025 - GCC 14 is the first major version to support the new capabilities of a wide range of computer architectures, including AMD CPUs based on the Zen 5 core. It also introduces many new features.
🌐
Debian
packages.debian.org › sid › gcc-14
Debian -- Details of package gcc-14 in sid
This is the GNU C compiler, a fairly portable optimizing compiler for C · This page is also available in the following languages (How to set the default document language):
🌐
DEV Community
dev.to › marcosplusplus › how-to-install-gcc-14-and-use-c23-41od
How to Install GCC 14 and Use C++23 - DEV Community
April 15, 2025 - Several new features such as: std::print, std::println and others. GCC 14 has several... Tagged with cpp, gcc, c.
🌐
Reddit
reddit.com › r/c_programming › how important are gcc versions?
r/C_Programming on Reddit: How important are gcc versions?
May 13, 2024 -

I have started getting unto assembly and optimising code and I was wandering how important if at all is it to upgrade the computer I am using.

Currently I am on gcc 11.4 which feels fairly old at this point when I am looking at what's out there.

Are the differences between versions thst big or is it generally fairly unimportant

🌐
Homebrew
formulae.brew.sh › formula › gcc@14
gcc@14 — Homebrew Formulae
brew install gcc@14 · GNU compiler collection · https://gcc.gnu.org/ License: GPL-3.0-or-later WITH GCC-exception-3.1 · Development: Pull requests · Formula JSON API: /api/formula/gcc@14.json · Formula code: gcc@14.rb on GitHub ·
🌐
GNU
gcc.gnu.org
GCC, the GNU Compiler Collection - GNU Project
The GNU Compiler Collection includes front ends for C, C++, Objective-C, Objective-C++, Fortran, Ada, Go, D, Modula-2, COBOL, Rust, and Algol 68 as well as libraries for these languages (libstdc++,...). GCC was originally written as the compiler for the GNU operating system.
🌐
Fedora Discussion
discussion.fedoraproject.org › ask fedora
GCC 14 on Fedora 42 - Fedora Discussion
May 22, 2025 - So, I found this page which mentions, correctly, that package gcc-14 exists, and I installed it. Now I want this GCC to be the default one. The page suggests this: Using the alternatives system: sudo alternatives --config gcc This displays a menu allowing you to select the default gcc command.
🌐
Linux Mint Forums
forums.linuxmint.com › board index › main edition support › software & applications
Problem with package gcc-14-base - Linux Mint Forums
April 15, 2025 - I would like to get some understanding of what is going on. It's quite clear: those packages need gcc-14-base, so it is installed. Both are also installed on my system. Notice that gcc-14 is NOT installed. Just the base, not the compiler itself. Only gcc-13 is installed as the compiler for the system.
🌐
Raspberry Pi Forums
forums.raspberrypi.com › board index › programming › c/c++
Using GCC 14 on Debian bookworm - Raspberry Pi Forums
I can't help with your compilation, but I suspect that GCC 14 will be available in the bookworm backports repository.