Skip to content

Commit 9c91314886 breaks YVES/Sereal-Decoder-4.018.tar.gz on threaded perl #19382

@andk

Description

@andk

Description

During compilation of YVES/Sereal-Decoder-4.018.tar.gz with a threaded perl built with v5.35.5-32-g9c91314886 the following error is thrown:

cc -c  -I. -D_REENTRANT -D_GNU_SOURCE -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2 -O3 -Werror=declaration-after-statement    -DVERSION=\"4.018\" -DXS_VERSION=\"4.018\" -fPIC "-I/home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.35.5-32-g9c91314886/1e0c/lib/5.35.6/x86_64-linux-thread-multi/CORE"  -DNDEBUG -DHAVE_ZSTD Decoder.c

In file included from /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.35.5-32-g9c91314886/1e0c/lib/5.35.6/x86_64-linux-thread-multi/CORE/perl.h:7135,
                 from Decoder.xs:6:
/home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.35.5-32-g9c91314886/1e0c/lib/5.35.6/x86_64-linux-thread-multi/CORE/inline.h: In function ‘Perl_cop_file_avn’:
/home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.35.5-32-g9c91314886/1e0c/lib/5.35.6/x86_64-linux-thread-multi/CORE/inline.h:3439:5: error: ISO C90 forbids mixed declarations and code [-Werror=declaration-after-statement]
 3439 |     const char *file = CopFILE(cop);
      |     ^~~~~
cc1: some warnings being treated as errors
make: *** [Makefile:368: Decoder.o] Error 1

I see same result with v5.35.8-28-gebfc9d5d0d given a threaded perl.

Steps to Reproduce

cpan -i Sereal::Decoder

Expected behavior

Module should be built, tested and installed

Perl configuration

Summary of my perl5 (revision 5 version 35 subversion 6) configuration:
  Commit id: 9c913148860b0e83e6149d37e86cdb29663ee812
  Platform:
    osname=linux
    osvers=5.15.0-2-amd64
    archname=x86_64-linux-thread-multi
    uname='linux k93msid 5.15.0-2-amd64 #1 smp debian 5.15.5-2 (2021-12-18) x86_64 gnulinux '
    config_args='-Dprefix=/home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.35.5-32-g9c91314886/1e0c -Dmyhostname=k93msid -Dinstallusrbinperl=n -Uversiononly -Dusedevel -des -Ui_db -Dlibswanted=cl pthread socket inet nsl gdbm dbm malloc dl ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat -Duseithreads -Uuselongdouble -DEBUGGING=-g'
    hint=recommended
    useposix=true
    d_sigaction=define
    useithreads=define
    usemultiplicity=define
    use64bitint=define
    use64bitall=define
    uselongdouble=undef
    usemymalloc=n
    default_inc_excludes_dot=define
  Compiler:
    cc='cc'
    ccflags ='-D_REENTRANT -D_GNU_SOURCE -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2'
    optimize='-O2 -g'
    cppflags='-D_REENTRANT -D_GNU_SOURCE -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include'
    ccversion=''
    gccversion='11.2.0'
    gccosandvers=''
    intsize=4
    longsize=8
    ptrsize=8
    doublesize=8
    byteorder=12345678
    doublekind=3
    d_longlong=define
    longlongsize=8
    d_longdbl=define
    longdblsize=16
    longdblkind=3
    ivtype='long'
    ivsize=8
    nvtype='double'
    nvsize=8
    Off_t='off_t'
    lseeksize=8
    alignbytes=8
    prototype=define
  Linker and Libraries:
    ld='cc'
    ldflags =' -fstack-protector-strong -L/usr/local/lib'
    libpth=/usr/local/lib /usr/lib/x86_64-linux-gnu /usr/lib /lib/x86_64-linux-gnu /lib
    libs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc
    perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc
    libc=libc-2.33.so
    so=so
    useshrplib=false
    libperl=libperl.a
    gnulibc_version='2.33'
  Dynamic Linking:
    dlsrc=dl_dlopen.xs
    dlext=so
    d_dlsymun=undef
    ccdlflags='-Wl,-E'
    cccdlflags='-fPIC'
    lddlflags='-shared -O2 -g -L/usr/local/lib -fstack-protector-strong'


Characteristics of this binary (from libperl): 
  Compile-time options:
    HAS_TIMES
    MULTIPLICITY
    PERLIO_LAYERS
    PERL_COPY_ON_WRITE
    PERL_DONT_CREATE_GVSV
    PERL_MALLOC_WRAP
    PERL_OP_PARENT
    PERL_PRESERVE_IVUV
    PERL_USE_DEVEL
    USE_64_BIT_ALL
    USE_64_BIT_INT
    USE_ITHREADS
    USE_LARGE_FILES
    USE_LOCALE
    USE_LOCALE_COLLATE
    USE_LOCALE_CTYPE
    USE_LOCALE_NUMERIC
    USE_LOCALE_TIME
    USE_PERLIO
    USE_PERL_ATOF
    USE_REENTRANT_API
    USE_THREAD_SAFE_LOCALE
  Built under linux
  Compiled at Jan 30 2022 07:15:24
  @INC:
    /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.35.5-32-g9c91314886/1e0c/lib/site_perl/5.35.6/x86_64-linux-thread-multi
    /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.35.5-32-g9c91314886/1e0c/lib/site_perl/5.35.6
    /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.35.5-32-g9c91314886/1e0c/lib/5.35.6/x86_64-linux-thread-multi
    /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.35.5-32-g9c91314886/1e0c/lib/5.35.6

Metadata

Metadata

Assignees

No one assigned

    Labels

    BBCBlead Breaks CPAN - changes in blead broke a cpan module(s)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions