Skip to content

Rapidjson cannot be found even env variable is set #5069

@QuantumMisaka

Description

@QuantumMisaka

Describe the bug

when using toolchain to build ABACUS with -DBUILD_RAPIDJSON=ON, in build process the rapidjson will not be found even rapidjson is existing

Loading mpi version 2021.8.0
-- The CXX compiler identification is IntelLLVM 2023.2.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /data/softwares/intel/oneapi/compiler/2023.2.1/linux/bin/icpx - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Warning at CMakeLists.txt:45 (find_package):
  By not providing "FindRapidJSON.cmake" in CMAKE_MODULE_PATH this project
  has asked CMake to find a package configuration file provided by
  "RapidJSON", but CMake did not find one.

  Could not find a package configuration file provided by "RapidJSON" with
  any of the following names:

    RapidJSONConfig.cmake
    rapidjson-config.cmake

  Add the installation prefix of "RapidJSON" to CMAKE_PREFIX_PATH or set
  "RapidJSON_DIR" to a directory containing one of the above files.  If
  "RapidJSON" provides a separate development package or SDK, be sure it has
  been installed.


CMake Warning at CMakeLists.txt:47 (message):
  Rapidjson is not found, trying downloading from github, or you can install
  Rapidjson first and reinstall abacus.

As #4981 , setting the environment variable should let ABACUS find rapidjson, but this is not work in previous version of ABACUS.

Expected behavior

ABACUS can be built with rapidjson after setting export CPATH='path/to/rapidjson/include':$CPATH

To Reproduce

No response

Environment

No response

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).

Metadata

Metadata

Assignees

Labels

Input&OutputSuitable for coders without knowing too many DFT details

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions