Skip to contentSkip to conversation

Minimum compiler version (was: Re: [PATCH v5 0/4] Update gnulib and drop some patches)

DISCUSSION Glenn Washburn 4 participants 4 messages Feb 26, 2022 – Mar 4, 2022

lore
Share & tools
lore
#0 lore raw
Quoted 9 lines · On Tue, 22 Feb 2022 18:17:51 +0100 Daniel Kiper <[email protected]> wrote:

The GRUB INSTALL file says:

The Requirements
================

GRUB depends on some software packages installed into your system. If you don't have any of them, please obtain and install them before configuring the GRUB.

Quoted 6 lines

* GCC 5.1.0 or later

So, even if it is old it is perfectly valid compiler according to the GRUB docs.

Hmmm... What are the latest gnulib minimal compiler, linker, etc. requirements?

In working on the testing system, I noticed that kernel.org provides no RISC cross compilers for x86_64 for GCC version < 7.3. I'm not sure if that's because there isn't support in earlier versions. The other recommended pre-built cross toolchain site toolchains.bootlin.com only has prebuilts for somewhat recent GCC versions (9.3 is the earliest for risc32/64). So the documentation above may be misleading for RISC.

I like the idea of really old GCC versions be supported if its not a burden, but are we actually testing that GRUB does compile with 5.1.0 (at a minimum even for releases)? I think the minimum supported version of GCC should be a version that is actually tested with.

GCC 5.1.0 looks like it came out on April 22, 2015[1] and 5.2 was used in Ubuntu Xenial from 2016 (which is no longer supported). At what point do we bump up the minimum supported version? And doing so wouldn't mean that GRUB can't be compiled with eariler versions of GCC, it just means we don't test that. I also think it would be acceptable to accept patches that fix issues with compiling on GCC versions less than the stated minimum supported version (with in reason and subject to discretion).

One idea is to update the minimum supported version every release cycle to the lowest GCC version that is about 5 years old (that's artitrary but seems reasonable).

I'm interested in this because it seems to imply that for the testing system it should do two compilations for every target, one for the munimum supported GCC and one for a somewhat recent version.

Glenn

[1] https://gcc.gnu.org/releases.html

#1 lore raw
Quoted 16 lines · Glenn Washburn
Quoted 14 lines · On Tue, 22 Feb 2022 18:17:51 +0100 Daniel Kiper <[email protected]> wrote:

The GRUB INSTALL file says:

The Requirements
================

GRUB depends on some software packages installed into your system. If you don't have any of them, please obtain and install them before configuring the GRUB.

* GCC 5.1.0 or later

So, even if it is old it is perfectly valid compiler according to the GRUB docs.

Quoted 8 lines
Quoted 1 line

Hmmm... What are the latest gnulib minimal compiler, linker, etc. requirements?

In working on the testing system, I noticed that kernel.org provides no RISC cross compilers for x86_64 for GCC version < 7.3. I'm not sure if that's because there isn't support in earlier versions. The other recommended pre-built cross toolchain site toolchains.bootlin.com only has prebuilts for somewhat recent GCC versions (9.3 is the earliest for risc32/64). So the documentation above may be misleading for RISC.

RISC-V support was first introduced in GCC 7:
https://gcc.gnu.org/gcc-7/changes.html

Best regards

Heinrich

Quoted 31 lines

I like the idea of really old GCC versions be supported if its not a burden, but are we actually testing that GRUB does compile with 5.1.0 (at a minimum even for releases)? I think the minimum supported version of GCC should be a version that is actually tested with.

GCC 5.1.0 looks like it came out on April 22, 2015[1] and 5.2 was used in Ubuntu Xenial from 2016 (which is no longer supported). At what point do we bump up the minimum supported version? And doing so wouldn't mean that GRUB can't be compiled with eariler versions of GCC, it just means we don't test that. I also think it would be acceptable to accept patches that fix issues with compiling on GCC versions less than the stated minimum supported version (with in reason and subject to discretion).

One idea is to update the minimum supported version every release cycle to the lowest GCC version that is about 5 years old (that's artitrary but seems reasonable).

I'm interested in this because it seems to imply that for the testing system it should do two compilations for every target, one for the munimum supported GCC and one for a somewhat recent version.

Glenn

[1] https://gcc.gnu.org/releases.html

_______________________________________________
Grub-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/grub-devel

#2 lore raw
In reply to Glenn Washburn
Quoted 9 lines · Glenn Washburn

GCC 5.1.0 looks like it came out on April 22, 2015[1] and 5.2 was used in Ubuntu Xenial from 2016 (which is no longer supported). At what point do we bump up the minimum supported version? And doing so wouldn't mean that GRUB can't be compiled with eariler versions of GCC, it just means we don't test that. I also think it would be acceptable to accept patches that fix issues with compiling on GCC versions less than the stated minimum supported version (with in reason and subject to discretion).

Quoted 7 lines

One idea is to update the minimum supported version every release cycle to the lowest GCC version that is about 5 years old (that's artitrary but seems reasonable).

I'm interested in this because it seems to imply that for the testing system it should do two compilations for every target, one for the munimum supported GCC and one for a somewhat recent version.

I support raising the minimum compiler version.

Looking at https://www.gnu.org/software/gcc/releases.html , a five-year proposal would raise to gcc-7.

Be well,
--Robbie

#3 lore raw
Quoted 11 lines · Robbie Harwood
Quoted 9 lines · Glenn Washburn

GCC 5.1.0 looks like it came out on April 22, 2015[1] and 5.2 was used in Ubuntu Xenial from 2016 (which is no longer supported). At what point do we bump up the minimum supported version? And doing so wouldn't mean that GRUB can't be compiled with eariler versions of GCC, it just means we don't test that. I also think it would be acceptable to accept patches that fix issues with compiling on GCC versions less than the stated minimum supported version (with in reason and subject to discretion).

Quoted 3 lines
Quoted 3 lines

One idea is to update the minimum supported version every release cycle to the lowest GCC version that is about 5 years old (that's artitrary but seems reasonable).

I think we should support a given minimum compiler version until it does not require a lot of effort from our side. So, as long as possible...

Quoted 3 lines
Quoted 3 lines

I'm interested in this because it seems to imply that for the testing system it should do two compilations for every target, one for the munimum supported GCC and one for a somewhat recent version.

I fully agree with this.

Quoted 4 lines

I support raising the minimum compiler version.

Looking at https://www.gnu.org/software/gcc/releases.html , a five-year proposal would raise to gcc-7.

I am OK with this because as it was pointed out in other places older compilers do not support RISC-V builds. Of course if I do not hear a lot of complaints... :-)

So, I am looking forward for an INSTALL file patch...

Daniel