Created attachment 858235 [details] Log of failed build with GCC 12 If I try to build dev-lang/python (3.9, 3.10 or 3.11) with GCC 12, I get a compilation error "error: inlining failed in call to 'always_inline'" in mpdecimal.c. If I switch back to GCC 11 (with `eselect gcc set 1`) then the build succeeds.
Created attachment 858237 [details] Output of `emerge --info` with GCC 12 selected
Created attachment 858239 [details] Log of successful build with GCC 11
Created attachment 858241 [details] Output of `emerge --info` with GCC 11 selected
I found a possibly relevant upstream bug at https://github.com/python/cpython/issues/94847
Following up on the upstream issue, the build succeeds if I remove the debug flags ('-g' etc.) from CFLAGS.
(In reply to Chris Kerr from comment #5) > Following up on the upstream issue, the build succeeds if I remove the debug > flags ('-g' etc.) from CFLAGS. Interestingly, that is not what was mentioned in the upstream issue. The '--with-pydebug' flag is for changing the preprocessor declarations to enable assertions etc, not for changing the compiler flags to generate debug information, at least according to the documentation. The upstream issue also says that the problem has been fixed in 3.11, but this is not the case, at least for me.
That commit should've landed in several of the 3.11 releases so I guess it's just similar and not the same exact issue. Interestingly, we also had bug 895080.
Is this specific to PPC64? I've tried building with `-g` on amd64 and it seems to have built fine.
(In reply to Michał Górny from comment #8) > Is this specific to PPC64? I've tried building with `-g` on amd64 and it > seems to have built fine. It could be. I don't have an amd64 gentoo machine to test on.
Created attachment 858757 [details] Log of failed build of dev-lang/perl It seems that this is not Python-specific - I got a similar "inlining failed in call to 'always_inline'" error when building dev-lang/perl with `-g` and GCC 12. The configure script output says that it detects that "always_inline" is supported, but then using it in the code fails.
That bug was fixed a while ago for CPython. For Perl, it's considered a bug in Perl to rely on always_inline like that from GCC.