• Bug#1102676: reflect-cpp: FTBFS on armel, armhf, i386: error: =?UTF-8?Q

    From Sebastian Ramacher@21:1/5 to All on Fri Apr 11 21:40:01 2025
    Source: reflect-cpp
    Version: 0.18.0+ds-1
    Severity: serious
    Tags: ftbfs
    Justification: fails to build from source (but built successfully in the past) X-Debbugs-Cc: sramacher@debian.org

    Dear maintainer,

    reflect-cpp fails to build on armel, armhf, and i386:

    https://buildd.debian.org/status/fetch.php?pkg=reflect-cpp&arch=i386&ver=0.18.0%2Bds-1&stamp=1744354989&raw=0

    [69/544] /usr/bin/c++ -I/build/reproducible-path/reflect-cpp-0.18.0+ds/include -I/build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/thirdparty -I/build/reproducible-path/reflect-cpp-0.18.0+ds/obj-i686-linux-gnu/include -isystem //include -
    isystem /usr/include/libbson-1.0 -g -O2 -ffile-prefix-map=/build/reproducible-path/reflect-cpp-0.18.0+ds=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -O3 -Wall -Werror -ggdb -ftemplate-backtrace-limit=0 -std=
    gnu++20 -DGTEST_HAS_PTHREAD=1 -Winvalid-pch -include /build/reproducible-path/reflect-cpp-0.18.0+ds/obj-i686-linux-gnu/tests/json/CMakeFiles/reflect-cpp-json-tests.dir/cmake_pch.hxx -MD -MT tests/json/CMakeFiles/reflect-cpp-json-tests.dir/test_array.cpp.
    o -MF tests/json/CMakeFiles/reflect-cpp-json-tests.dir/test_array.cpp.o.d -o tests/json/CMakeFiles/reflect-cpp-json-tests.dir/test_array.cpp.o -c /build/reproducible-path/reflect-cpp-0.18.0+ds/tests/json/test_array.cpp
    FAILED: tests/json/CMakeFiles/reflect-cpp-json-tests.dir/test_array.cpp.o /usr/bin/c++ -I/build/reproducible-path/reflect-cpp-0.18.0+ds/include -I/build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/thirdparty -I/build/reproducible-path/reflect-cpp-0.18.0+ds/obj-i686-linux-gnu/include -isystem //include -isystem /usr/
    include/libbson-1.0 -g -O2 -ffile-prefix-map=/build/reproducible-path/reflect-cpp-0.18.0+ds=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -O3 -Wall -Werror -ggdb -ftemplate-backtrace-limit=0 -std=gnu++20 -
    DGTEST_HAS_PTHREAD=1 -Winvalid-pch -include /build/reproducible-path/reflect-cpp-0.18.0+ds/obj-i686-linux-gnu/tests/json/CMakeFiles/reflect-cpp-json-tests.dir/cmake_pch.hxx -MD -MT tests/json/CMakeFiles/reflect-cpp-json-tests.dir/test_array.cpp.o -MF
    tests/json/CMakeFiles/reflect-cpp-json-tests.dir/test_array.cpp.o.d -o tests/json/CMakeFiles/reflect-cpp-json-tests.dir/test_array.cpp.o -c /build/reproducible-path/reflect-cpp-0.18.0+ds/tests/json/test_array.cpp
    In file included from /usr/include/c++/14/string_view:48,
    from /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/Field.hpp:5,
    from /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/AddStructName.hpp:6,
    from /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl.hpp:10,
    from /build/reproducible-path/reflect-cpp-0.18.0+ds/obj-i686-linux-gnu/tests/json/CMakeFiles/reflect-cpp-json-tests.dir/cmake_pch.hxx:5,
    from <command-line>:
    In static member function ‘static constexpr std::char_traits<char>::char_type* std::char_traits<char>::copy(char_type*, const char_type*, std::size_t)’,
    inlined from ‘constexpr std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]’ at /usr/
    include/c++/14/bits/basic_string.h:688:23,
    inlined from ‘constexpr std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(__cxx11::basic_string<_CharT, _Traits, _Allocator>&&, const _CharT*) [with _CharT = char; _Traits = char_traits<char>; _Alloc = allocator<char>]’ at /
    usr/include/c++/14/bits/basic_string.h:3735:43,
    inlined from ‘std::optional<rfl::Error> rfl::parsing::ArrayReader<R, W, ProcessorsType, T, _size>::read(const InputVarType&) const [with R = rfl::json::Reader; W = rfl::json::Writer; ProcessorsType = rfl::Processors<>; T = test_array::Person;
    unsigned int _size = 3]’ at /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/parsing/ArrayReader.hpp:40:56:
    /usr/include/c++/14/bits/char_traits.h:427:56: error: ‘void* __builtin_memcpy(void*, const void*, unsigned int)’ forming offset [24, 42] is out of the bounds [0, 24] of object ‘<anonymous>’ with type ‘std::__cxx11::basic_string<char>’ [-
    Werror=array-bounds=]
    427 | return static_cast<char_type*>(__builtin_memcpy(__s1, __s2, __n));
    | ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
    In file included from /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/parsing/Parser_array.hpp:14,
    from /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/parsing/Parser.hpp:4,
    from /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/generic/Parser.hpp:4,
    from /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/generic/read.hpp:10,
    from /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/from_generic.hpp:5,
    from /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl.hpp:61:
    /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/parsing/ArrayReader.hpp: In member function ‘std::optional<rfl::Error> rfl::parsing::ArrayReader<R, W, ProcessorsType, T, _size>::read(const InputVarType&) const [with R = rfl::json::Reader; W =
    rfl::json::Writer; ProcessorsType = rfl::Processors<>; T = test_array::Person; unsigned int _size = 3]’:
    /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/parsing/ArrayReader.hpp:40:56: note: ‘<anonymous>’ declared here
    40 | return Error("Expected " + std::to_string(size_) +
    | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
    41 | " elements, got at least " + std::to_string(size_ + 1) +
    | ~~~~~~~~~~~~~~~~~~~~~~~~~~
    In static member function ‘static constexpr std::char_traits<char>::char_type* std::char_traits<char>::copy(char_type*, const char_type*, std::size_t)’,
    inlined from ‘constexpr std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]’ at /usr/
    include/c++/14/bits/basic_string.h:688:23,
    inlined from ‘constexpr std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::operator+(__cxx11::basic_string<_CharT, _Traits, _Allocator>&&, const _CharT*) [with _CharT = char; _Traits = char_traits<char>; _Alloc = allocator<char>]’ at /
    usr/include/c++/14/bits/basic_string.h:3735:43,
    inlined from ‘std::optional<rfl::Error> rfl::parsing::ArrayReader<R, W, ProcessorsType, T, _size>::check_size() const [with R = rfl::json::Reader; W = rfl::json::Writer; ProcessorsType = rfl::Processors<>; T = test_array::Person; unsigned int _size
    = 3]’ at /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/parsing/ArrayReader.hpp:30:56,
    inlined from ‘rfl::parsing::Parser<rfl::json::Reader, rfl::json::Writer, std::array<test_array::Person, 3>, rfl::Processors<> >::read(const rfl::json::Reader&, const InputVarType&)::<lambda(const rfl::parsing::Parser<rfl::json::Reader, rfl::json::
    Writer, std::array<test_array::Person, 3>, rfl::Processors<> >::InputArrayType&)>’ at /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/parsing/Parser_array.hpp:45:36:
    /usr/include/c++/14/bits/char_traits.h:427:56: error: ‘void* __builtin_memcpy(void*, const void*, unsigned int)’ forming offset [24, 33] is out of the bounds [0, 24] of object ‘<anonymous>’ with type ‘std::__cxx11::basic_string<char>’ [-
    Werror=array-bounds=]
    427 | return static_cast<char_type*>(__builtin_memcpy(__s1, __s2, __n));
    | ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
    /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/parsing/ArrayReader.hpp: In function ‘rfl::parsing::Parser<rfl::json::Reader, rfl::json::Writer, std::array<test_array::Person, 3>, rfl::Processors<> >::read(const rfl::json::Reader&, const
    InputVarType&)::<lambda(const rfl::parsing::Parser<rfl::json::Reader, rfl::json::Writer, std::array<test_array::Person, 3>, rfl::Processors<> >::InputArrayType&)>’:
    /build/reproducible-path/reflect-cpp-0.18.0+ds/include/rfl/parsing/ArrayReader.hpp:30:56: note: ‘<anonymous>’ declared here
    30 | return Error("Expected " + std::to_string(size_) + " elements, got " +
    | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
    cc1plus: all warnings being treated as errors

    Cheers
    --
    Sebastian Ramacher

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Debian Bug Tracking System@21:1/5 to All on Sat Apr 12 17:50:01 2025
    This is a multi-part message in MIME format...

    Your message dated Sat, 12 Apr 2025 15:39:07 +0000
    with message-id <E1u3cwl-00Aytw-AP@fasolo.debian.org>
    and subject line Bug#1102676: fixed in reflect-cpp 0.18.0+ds-2
    has caused the Debian Bug report #1102676,
    regarding reflect-cpp: FTBFS on armel, armhf, i386: error: ‘void* __builtin_memcpy(void*, const void*, unsigned int)’ forming offset [24, 42] is out of the bounds [0, 24] of object ‘<anonymous>’ with type ‘std::__cxx11::basic_string<char>’ [-
    Werror=array-bounds=]
    to be marked as done.

    This means that you claim that the problem has been dealt with.
    If this is not the case it is now your responsibility to reopen the
    Bug report if necessary, and/or fix the problem forthwith.

    (NB: If you are a system administrator and have no idea what this
    message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact owner@bugs.debian.org
    immediately.)


    --
    1102676: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1102676
    Debian Bug Tracking System
    Contact owner@bugs.debian.org with problems

    Received: (at submit) by bugs.debian.org; 11 Apr 2025 19:29:22 +0000 X-Spam-Checker-Version: SpamAssassin 3.4.6-bugs.debian.org_2005_01_02
    (2021-04-09) on buxtehude.debian.org
    X-Spam-Level:
    X-Spam-Status: No, score=-105.9 required=4.0 tests=BAYES_00,DKIMWL_WL_HIGH,
    DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FROMDEVELOPER,
    SPF_HELO_NONE,SPF_NONE,UNPARSEABLE_RELAY,USER_IN_DKIM_WELCOMELIST,
    USER_IN_DKIM_WHITELIST autolearn=ham autolearn_force=no
    version=3.4.6-bugs.debian.org_2005_01_02
    X-Spam-Bayes: score:0.0000 Tokens: new, 54; hammy, 150; neutral, 144; spammy,
    0. spammytokens:
    hammytokens:0.000-+--Hx-spam-relays-external:sk:stravin,
    0.000-+--H*RT:sk:stravin, 0.000-+--Hx-spam-relays-external:311,
    0.000-+--H*RT:311, 0.000-+--H*RT:108
    Return-path: <sramacher@debian.org>
    Received: from stravinsky.debian.org ([2001:41b8:202:deb::311:108]: