File tree Expand file tree Collapse file tree 7 files changed +65
-21
lines changed Expand file tree Collapse file tree 7 files changed +65
-21
lines changed Original file line number Diff line number Diff line change 1- [submodule "deps/LibRI "]
2- path = deps/LibRI
3- url = https://github.com/abacusmodeling/LibRI.git
4- branch = master
5- [submodule "deps/LibComm "]
6- path = deps/LibComm
7- url = https://github.com/abacusmodeling/LibComm.git
8- branch = master
91[submodule "deps/libpaw_interface "]
102 path = deps/libpaw_interface
113 url = https://github.com/wenfei-li/libpaw_interface
Original file line number Diff line number Diff line change @@ -538,13 +538,10 @@ endif()
538538if (ENABLE_LIBRI)
539539 set_if_higher(CMAKE_CXX_STANDARD 14)
540540 if (LIBRI_DIR)
541- include_directories (${LIBRI_DIR} /include )
542- elseif (GIT_SUBMODULE)
543- git_submodule_update()
544- include_directories (${CMAKE_CURRENT_SOURCE_DIR} /deps/LibRI/include )
545541 else ()
546- message (FATAL_ERROR "Must provide LIBRI_DIR for RI related features." )
542+ find_package (LibRI REQUIRED )
547543 endif ()
544+ include_directories (${LIBRI_DIR} /include )
548545 target_link_libraries (${ABACUS_BIN_NAME} ri module_exx_symmetry)
549546 add_compile_definitions (__EXX EXX_DM=3 EXX_H_COMM=2 TEST_EXX_LCAO=0
550547 TEST_EXX_RADIAL=1)
@@ -555,13 +552,10 @@ if(ENABLE_LIBRI OR DEFINED LIBCOMM_DIR)
555552endif ()
556553if (ENABLE_LIBCOMM)
557554 if (LIBCOMM_DIR)
558- include_directories (${LIBCOMM_DIR} /include )
559- elseif (GIT_SUBMODULE)
560- git_submodule_update()
561- include_directories (${CMAKE_CURRENT_SOURCE_DIR} /deps/LibComm/include )
562555 else ()
563- message (FATAL_ERROR "Must provide LIBCOMM_DIR for RI related features." )
556+ find_package (LibComm REQUIRED )
564557 endif ()
558+ include_directories (${LIBCOMM_DIR} /include )
565559endif ()
566560
567561if (ENABLE_PAW)
Original file line number Diff line number Diff line change 1+ ###############################################################################
2+ # - Find LibComm
3+ # Find the native LibComm files.
4+ #
5+ # LIBCOMM_FOUND - True if LibComm is found.
6+ # LIBCOMM_DIR - Where to find LibComm files.
7+
8+ find_path (LIBCOMM_DIR
9+ include /Comm/Comm_Tools.h
10+ HINTS ${LIBCOMM_DIR}
11+ HINTS ${LibComm_DIR}
12+ HINTS ${libcomm_DIR}
13+ )
14+
15+ if (NOT LIBCOMM_DIR)
16+ include (FetchContent)
17+ FetchContent_Declare(
18+ LibComm
19+ URL https://github.com/abacusmodeling/LibComm/archive/refs/tags/v0.1.1.tar.gz
20+ )
21+ FetchContent_Populate(LibComm)
22+ set (LIBCOMM_DIR ${libcomm_SOURCE_DIR} )
23+ endif ()
24+ # Handle the QUIET and REQUIRED arguments and
25+ # set LIBCOMM_FOUND to TRUE if all variables are non-zero.
26+ include (FindPackageHandleStandardArgs)
27+ find_package_handle_standard_args(LibComm DEFAULT_MSG LIBCOMM_DIR)
28+
29+ # Copy the results to the output variables and target.
30+ mark_as_advanced (LIBCOMM_DIR)
Original file line number Diff line number Diff line change 1+ ###############################################################################
2+ # - Find LibRI
3+ # Find the native LibRI files.
4+ #
5+ # LIBRI_FOUND - True if LibRI is found.
6+ # LIBRI_DIR - Where to find LibRI files.
7+
8+ find_path (LIBRI_DIR
9+ include /RI/version .h
10+ HINTS ${LIBRI_DIR}
11+ HINTS ${LibRI_DIR}
12+ HINTS ${libri_DIR}
13+ )
14+
15+ if (NOT LIBRI_DIR)
16+ include (FetchContent)
17+ FetchContent_Declare(
18+ LibRI
19+ URL https://github.com/abacusmodeling/LibRI/archive/refs/tags/v0.2.1.1.tar.gz
20+ )
21+ FetchContent_Populate(LibRI)
22+ set (LIBRI_DIR ${libri_SOURCE_DIR} )
23+ endif ()
24+ # Handle the QUIET and REQUIRED arguments and
25+ # set LIBRI_FOUND to TRUE if all variables are non-zero.
26+ include (FindPackageHandleStandardArgs)
27+ find_package_handle_standard_args(LibRI DEFAULT_MSG LIBRI_DIR)
28+
29+ # Copy the results to the output variables and target.
30+ mark_as_advanced (LIBRI_DIR)
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1212SCRIPT_DIR=" $( cd " $( dirname " $SCRIPT_NAME " ) /.." && pwd -P) "
1313
1414libcomm_ver=" 0.1.1"
15- libcomm_sha256=" 3764c934c895bfd9d8fd766d46e6e3d03230f8076e3edbcc31e10ff8f30075a4 "
15+ libcomm_sha256=" fa162a197678654f15d91a5a917cce7fb2748bd9b0e344363edea2db87547b72 "
1616source " ${SCRIPT_DIR} " /common_vars.sh
1717source " ${SCRIPT_DIR} " /tool_kit.sh
1818source " ${SCRIPT_DIR} " /signal_trap.sh
You can’t perform that action at this time.
0 commit comments