Bug#957675: perl: ftbfs with GCC-10

Niko Tyni ntyni at debian.org
Fri Apr 17 18:50:02 BST 2020


Control: tag -1 upstream

On Fri, Apr 17, 2020 at 06:26:17PM +0300, Niko Tyni wrote:
> On Fri, Apr 17, 2020 at 11:08:35AM +0000, Matthias Klose wrote:
> > Package: src:perl
> > Version: 5.30.0-9
> > Severity: normal
> > Tags: sid bullseye
> > User: debian-gcc at lists.debian.org
> > Usertags: ftbfs-gcc-10

> > Failed 6 tests out of 2533, 99.76% okay.
> > 	../cpan/Memoize/t/tie_gdbm.t
> > 	../cpan/Memoize/t/tie_ndbm.t
> > 	../ext/GDBM_File/t/gdbm.t
> > 	../ext/NDBM_File/t/ndbm.t
> > 	../ext/ODBM_File/t/odbm.t
> > 	../lib/AnyDBM_File.t
> 
> I can reproduce this. It happens at both -O2 and -O0, but goes away when
> building with -DDEBUGGING (so our /usr/bin/debugperl).

This is a 26 years old bug.

>From regen-configure/U/compline/ccflags.U :

  ?RCS: Revision 3.0.1.4  1994/05/06  14:28:45  ram
  ?RCS: patch23: -fpcc-struct-return only needed in gcc 1.x (ADO)

  [...]
          case "$gccversion" in
        1*) dflt="$dflt -fpcc-struct-return" ;;
        esac

So the perl Configure script adds -fpcc-struct-return to the compiler
flags if the GCC version starts with number 1. This changes the ABI,
causing a segmentation fault when calling external code in libgdbm.

Should be easy to fix.
-- 
Niko




More information about the Perl-maintainers mailing list