Skip to content

[C++] Meson compilation with gcc 14.2 fails with RapidJSON error #47039

Closed

Description

@WillAyd

Describe the bug, including details regarding any error messages, version, and platform.

When compiling the project with gcc 14.2, the compiler throws an error when including the RapidJSON dependency:

[160/473] Compiling C++ object src/arrow/libarrow.so.p/integration_json_integration.cc.o
FAILED: src/arrow/libarrow.so.p/integration_json_integration.cc.o 
c++ -Isrc/arrow/libarrow.so.p -Isrc/arrow -I../src/arrow -Isrc -I../src -I../thirdparty/hadoop/include -I../thirdparty/flatbuffers/include -fvisibility=hidden -fdiagnostics-color=always -fsanitize=address,undefined -fno-omit-frame-pointer -D_GLIBCXX_ASSERTIONS=1 -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -std=c++17 -O0 -g -Wno-unused-parameter -Wno-array-bounds -Wno-stringop-overflow -Wno-aggressive-loop-optimizations -Wno-nonnull -fPIC -pthread -isystem../subprojects/rapidjson-1.1.0/include -DARROW_EXPORTING -MD -MQ src/arrow/libarrow.so.p/integration_json_integration.cc.o -MF src/arrow/libarrow.so.p/integration_json_integration.cc.o.d -o src/arrow/libarrow.so.p/integration_json_integration.cc.o -c ../src/arrow/integration/json_integration.cc
In file included from ../src/arrow/integration/json_internal.h:26,
                 from ../src/arrow/integration/json_integration.cc:27:
../subprojects/rapidjson-1.1.0/include/rapidjson/document.h: In member function ‘arrow::rapidjson::GenericStringRef<CharType>& arrow::rapidjson::GenericStringRef<CharType>::operator=(const arrow::rapidjson::GenericStringRef<CharType>&)’:
../subprojects/rapidjson-1.1.0/include/rapidjson/document.h:319:82: error: assignment of read-only member ‘arrow::rapidjson::GenericStringRef<CharType>::length’
  319 |     GenericStringRef& operator=(const GenericStringRef& rhs) { s = rhs.s; length = rhs.length; }
      |                                                                           ~~~~~~~^~~~~~~~~~~~

This looks to be a long standing issue upstream (see Tencent/rapidjson#2277) that was fixed some time ago, but RapidJSON has not had a release in quite some time.

It looks like the CMake version uses git hash 232389d4f1012dddec4ef84861face2d2ba85709 so we should probably bump the Meson configuration to use that as well

Component(s)

C++

Activity

  1. changed the title [-]Meson compilation with gcc 14.2 fails with RapidJSON error[/-] [+][C++] Meson compilation with gcc 14.2 fails with RapidJSON error[/+] on Jul 10, 2025
  2. added a commit that references this issue on Jul 10, 2025
  3. added a commit that references this issue on Aug 4, 2025
  4. added a commit that references this issue on Aug 15, 2025
  5. kou commented on Aug 15, 2025

    @kou
    Member

    Issue resolved by pull request 47041
    #47041

  6. added this to the 22.0.0 milestone on Aug 15, 2025
  7. added a commit that references this issue on Sep 3, 2025
  8. added a commit that references this issue on May 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions