Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build fail with rapidjson when using GCC=14.1.0 #4947

Closed
16 tasks
QuantumMisaka opened this issue Aug 11, 2024 · 2 comments
Closed
16 tasks

Build fail with rapidjson when using GCC=14.1.0 #4947

QuantumMisaka opened this issue Aug 11, 2024 · 2 comments
Labels
Compile & CICD & Docs Issues related to compiling ABACUS

Comments

@QuantumMisaka
Copy link

Describe the bug

When building ABACUS with rapidjson support with GCC 14.1.0, error occurs:

[ 90%] Building CXX object source/module_io/CMakeFiles/io_basic.dir/write_dos_lcao.cpp.o
[ 90%] Building CXX object source/module_io/CMakeFiles/io_basic.dir/write_orb_info.cpp.o
In file included from /lustre/home/2201110432/WORK/test/abacus-develop/source/module_io/json_output/abacusjson.h:12,
                 from /lustre/home/2201110432/WORK/test/abacus-develop/source/module_io/para_json.cpp:11:
/lustre/home/2201110432/WORK/test/abacus-develop/toolchain-gcc/install/rapidjson-1.1.0/include/rapidjson/document.h: In member function ‘rapidjson::GenericStringRef<CharType>& rapidjson::GenericStringRef<CharType>::operator=(const rapidjson::GenericStringRef<CharType>&)’:
/lustre/home/2201110432/WORK/test/abacus-develop/toolchain-gcc/install/rapidjson-1.1.0/include/rapidjson/document.h:319:82: error: assignment of read-only member ‘rapidjson::GenericStringRef<CharType>::length’
  319 |     GenericStringRef& operator=(const GenericStringRef& rhs) { s = rhs.s; length = rhs.length; }
      |                                                                           ~~~~~~~^~~~~~~~~~~~
gmake[2]: *** [source/module_io/CMakeFiles/io_basic.dir/build.make:440: source/module_io/CMakeFiles/io_basic.dir/para_json.cpp.o] Error 1
gmake[2]: *** Waiting for unfinished jobs....
[ 90%] Built target io_input
[ 90%] Built target io_advanced
gmake[1]: *** [CMakeFiles/Makefile2:1839: source/module_io/CMakeFiles/io_basic.dir/all] Error 2
gmake: *** [Makefile:136: all] Error 2
-- Install configuration: ""

For GCC 8.5.0 or 12.2.0, everything is normal.

Expected behavior

ABACUS with Rapidjson for GCC=14 should be normally built

To Reproduce

build ABACUS with GCC=14.1.0 with -DENABLE_RAPIDJSON=ON , along with:

  • SCALAPACK 2.2.1
  • OpenMPI 5.0.3
  • OpenBLAS 0.3.27
  • ELPA 2024.03.001
  • CEREAL

Environment

ABACUS version: https://github.com/QuantumMisaka/abacus-develop

Additional Context

No response

Task list for Issue attackers (only for developers)

  • Verify the issue is not a duplicate.
  • Describe the bug.
  • Steps to reproduce.
  • Expected behavior.
  • Error message.
  • Environment details.
  • Additional context.
  • Assign a priority level (low, medium, high, urgent).
  • Assign the issue to a team member.
  • Label the issue with relevant tags.
  • Identify possible related issues.
  • Create a unit test or automated test to reproduce the bug (if applicable).
  • Fix the bug.
  • Test the fix.
  • Update documentation (if necessary).
  • Close the issue and inform the reporter (if applicable).
@caic99
Copy link
Member

caic99 commented Aug 12, 2024

Tencent/rapidjson#2277

@mohanchen mohanchen added the Compile & CICD & Docs Issues related to compiling ABACUS label Aug 12, 2024
@WHUweiqingzhou
Copy link
Collaborator

Maybe wait for the fix?

@QuantumMisaka QuantumMisaka closed this as not planned Won't fix, can't repro, duplicate, stale Aug 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Compile & CICD & Docs Issues related to compiling ABACUS
Projects
None yet
Development

No branches or pull requests

4 participants