Foundational C++ Support Policy

Important: This policy applies only to open source projects that have opted in,and not to all Google open source projects.

Anything we consider to be supported means that we (theoretically) have anautomated test for it. We say "theoretically", because the full support matrixfor all combinations will be too big to fully test in practice. Practicalitysuggests a sparsely populated test matrix where we test every dimension in atleast one configuration. For example, we may test the oldest version of GCC thatwe support and the newest, but not every version in between.

See theFoundational C++ Support tablefor a list of supported versions that were chosen based on the policy describedin this document.

Operating Systems

We say that an operating system is supported if a user can reasonably get,install, and use our libraries using the tools and toolchains available for thatoperating system. In most cases this means the default toolchain for theplatform.

Support Criteria

  1. We will support releases of the following Linux distributions until thevendor drops support:

    1. Alpine
    2. Debian
    3. Fedora
    4. Red Hat
    5. Rocky
    6. openSUSE
    7. Ubuntu LTS

    Some vendors have different support levels depending on the age of theproduct. They may start with a "Full" or "Active" support period, andeventually go to a "Extended" or "Security Only" support period. We onlysupport our libraries with distributions still under "Active" or "Full"support.

    Note: these were chosen based on their popularity and theiravailability on Google Compute Engine.
  2. We will support Windows

    1. We will build using thenewest Windows server platform available
    2. We will support all the windows versions that Microsoft supports
      1. Windows client support
      2. Windows server support
  3. We will support macOS

    1. We will build using thenewest Xcode available
    2. We will support back to theoldest macOS target platform needed byChrome
  4. We will support iOS

    1. We will build using thenewest Xcode available
    2. We will support back to theoldest iOS target platform that has asimulator
      1. Ex: With Xcode 13.2, the oldest simulator is for iOS 12.4
  5. We will support Android

    1. We will build using thenewest Android NDK available and target itslowest supported API level (examplemeta/platforms.json)
  6. We will support new releases of other supported operating systems on ournormal release schedule within 90 days.

CPU Architectures

We will support our code on the following CPU architectures:

  • x86 (64- and 32-bit)
  • AArch64
  • iOS Emulator
  • Android Emulator

Compilers

For supported compilers, we'll start by considering the default toolchains oneach supported operating system (see above). We'll primarily focus on the mostpopular compilers in use, which are GCC, Clang, and MSVC according to a2021 JetBrains survey.

Support Criteria

  1. We do not support any compiler that is EOL as defined by the vendor.
  2. We support GCC and Clang on our supported Linux distros (see above). Wesupport the version installed by default (e.g.,apt install gcc), unlesswe've explicitly excluded support for that version because it doesn'tsupport other required policies of ours (e.g., we agree to remove GCC 4.8because of its incomplete C++11 support, as well as clang 3.x). If we cannotsupport the default version, we may instead support a newer version that'savailable from the vendor (e.g.,devtoolset-7on RHEL/CentOS 7)
  3. We support Apple Clang on our supported macOS/iOS versions.
  4. We support MSVC on our supported Windows versions.
    1. We support the MSVC versions that are in the Mainstream Support windowas defined by Microsoft'sFixed Lifecycle Policy.

C Standard Library

We will support theC Standard Library implementation that is included withthe operating systems we support. For operating systems where the C StandardLibrary is part of the toolchain, we will support the C Standard Libraryimplementation included with the toolchain.

For each supported C library implementation, we will support the earliestversion that ships with the operating systems and toolchains we support. Thisdoes not preclude supporting earlier versions.

In the interest of clarity, the list of C Standard Library implementations wesupport includesglibc,musl,Microsoft's CRT, andBSD libc.

Build Systems

There's no standard build system for C++. According toexternal developer surveys,CMake is the most popular with 55% usage, followed by autotools at 36%, andothers dropping from there. Bazel has 1% usage externally, however, it'sessential for at least one very important customer (i.e., Google).

Supporting multiple build systems has a real cost in increased testing, andmanual work or tooling to automate said work. We want to support the fewestbuild systems necessary to accommodate the most important use cases, which seemsto suggest supporting Bazel and CMake. CMake also integrates well with most IDEsand it knows how to use tools like MSVC and Xcode.

Support Criteria

  • We will not support any build system that is EOL by the vendor.
  • We will not support any build system that's not listed here.
  • Bazel —
    • We will support the latest Bazel release (excluding pre-releases), whichBazel calls theirActive release.
    • We will support the previous major version release for 12 monthsafter it transitions into maintenance mode.
  • CMake —
    • CMake < 3 is NOT supported (CMake 3.x started "modern CMake").
    • We support the oldest release that comes standard with a supporteddistro.
    • For example, as of Fall 2025 the oldest supported CMake would be3.13
  • Installs of our LTS releases should include the necessarypkgconfig files.
    • It's fine (and likely) if even non-LTS releases support this too.

C++ Language Standard

Maintaining support for any particular C++ standard forever (e.g., C++11) wouldmake it difficult to accommodate newer language features that customers willincreasingly come to expect. Eventually, Google's C++ libraries would appearoutdated to customers wanting modern features.

Support Criteria

Since C++ language standards are never formally deprecated or EOL'd, we'llevolve our support and drop earlier versions based on time and our supportedcompilers' default--std=.

  • We will support all modern C++ standards, from some oldest standard to thenewest.
  • We will drop support for our oldest supported C++ standard when one of thefollowing happens:
    • All supported compilers*default to a newer version
    • When 10 years pass since the standard's release date
    • Example: In 2023, if all supported compilers use C++17 as theirdefault, then we can drop support for C++14. Otherwise, we'll need towait until 2024, which would be 10 years after C++14 was released.
  • We will support the newest C++ language standard soon after the standard ispublished and compiler support is available.

* When considering compiler default versions, we're excluding Apple clang,which always defaults to C++98.

NOTE: dropping support for any given language version may not be immediatelyeffective even if the preceding criteria are met. Always consult theFoundational C++ Support tablefor the latest official support.

Changelog

DateDescription
2025-09Removed CentOS from the list of supported Linux distributions
2025-05Announce changes to Bazel support window starting with Bazel 8.0
2024-07Clarify what support period applies for distros with multiple support stages
2023-05Add clarification to consult table for latest supported versions
2022-10Documented supported CPU architectures
2022-09Announce changes to Bazel support window starting with Bazel 6.0

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-09-22 UTC.