Skip to content

move minimum supported gcc to gcc 12 for Node.js 23 #3806

Closed

Description

@richardlau

gcc no longer support gcc 10. I think it's time we plan to move up.

Due to compiler issues, we've already had to move Linux on s390x (LinuxONE) builds to use gcc 12: #3630
(FWIW the Red Hat team maintaining the V8 ports to Power and z also use gcc 12.)

My proposal is to move to gcc 12 as not all platforms that we support that we use gcc to build on have gcc 13 yet (e.g. AIX, IBM i). It would be easier to have the same baseline across all supported platforms, although it is not strictly necessarily (in the past we have had the minimum vary by platform, but in practice that forces Node.js to be compatible with the lowest out of the set).

Compilation of main is currently broken on gcc 12.2 (although not on RHEL 8) but would be fixed by landing nodejs/node#53728.

For releases on Linux we'd continue to use RHEL 8 (now in maintenance but good through to 2029) and use gcc-toolset-12 instead of gcc-toolset-10. This would mean we keep compatibility with glibc 2.28 and libstdc++ 6.0.25 (the base in RHEL 8) and Node.js 23 would continue to run in the same places that Node.js 22, 20 and 18 does. The exception to this is likely to be 32-bit arm (armv7l) which we use a custom cross-compiler for (as RHEL doesn't support armv7l). We would either need to generate a new gcc 12 cross-compiler (and check what that would mean in terms of run-time compatibility) or perhaps discuss whether armv7l is still a platform we continue to supply official binaries for.

Activity

  1. targos commented on Jul 28, 2024

    @targos
    Member

    I opened nodejs/node#54081 to change the warning threshold in Node.js.

    It includes a temporary commit that makes the build exit with code 1 when the version is too low so we can easily assess the impact on CI:

    https://ci.nodejs.org/job/node-test-pull-request/60690/

  2. added a commit that references this issue on Jul 28, 2024
  3. 18 remaining items

  4. richardlau commented on Sep 5, 2024

    @richardlau
    MemberAuthor
  5. targos commented on Sep 5, 2024

    @targos
    Member

    For SmartOS I saw that we have hosts with newer versions but they are not used by the Jenkins job

  6. richardlau commented on Sep 5, 2024

    @richardlau
    MemberAuthor

    For SmartOS I saw that we have hosts with newer versions but they are not used by the Jenkins job

    Being tracked under #3731 as part of the Equinix migration.

  7. targos commented on Sep 9, 2024

    @targos
    Member
  8. targos commented on Sep 10, 2024

    @targos
    Member

    Only SmartOS remains.

  9. richardlau commented on Sep 10, 2024

    @richardlau
    MemberAuthor

    For the new MNX hosted SmartOS machines which are meant to replace the equinix_mnx ones, it looks like SmartOS 23 has gcc 13 by default:

    $ ssh test-mnx-smartos23-x64-1 gcc --version
    gcc (GCC) 13.2.0
    Copyright (C) 2023 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions.  There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
    
    $
    

    while SmartOS 21 is 10:

    $ ssh test-mnx-smartos21-x64-1 gcc --version
    gcc (GCC) 10.4.0
    Copyright (C) 2020 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions.  There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
    
    $
    

    So perhaps this will be taken care of when the build issues on the new machines are resolved in #3731? cc @jperkin @ryanaslett

  10. richardlau commented on Oct 11, 2024

    @richardlau
    MemberAuthor

    Only SmartOS remains.

    I'm going to close this issue -- we have #3731 for tracking the migration of the SmartOS hosts and the gcc update should be taken care of by updating to SmartOS 23.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions