mirror of
https://github.com/PDB-REDO/dssp.git
synced 2026-06-04 13:44:21 +08:00
fix makefile
This commit is contained in:
@@ -98,7 +98,7 @@ set(THREADS_PREFER_PTHREAD_FLAG)
|
||||
find_package(Threads)
|
||||
find_package(libmcfp QUIET)
|
||||
|
||||
if(NOT libmcfp_FOUND)
|
||||
if(NOT (libmcfp_FOUND OR TARGET libmcfp))
|
||||
include(FetchContent)
|
||||
|
||||
if(CMAKE_VERSION GREATER_EQUAL 3.28)
|
||||
@@ -114,19 +114,21 @@ if(NOT libmcfp_FOUND)
|
||||
FetchContent_MakeAvailable(libmcfp)
|
||||
endif()
|
||||
|
||||
find_package(cifpp 7 QUIET)
|
||||
if(NOT TARGET cifpp AND NOT cifpp_FOUND)
|
||||
find_package(cifpp 7 QUIET)
|
||||
|
||||
if(NOT cifpp_FOUND)
|
||||
set(CIFPP_DOWNLOAD_CCD OFF)
|
||||
if(NOT cifpp_FOUND)
|
||||
set(CIFPP_DOWNLOAD_CCD OFF)
|
||||
|
||||
FetchContent_Declare(
|
||||
cifpp
|
||||
${EXLC}
|
||||
GIT_REPOSITORY https://github.com/pdb-redo/libcifpp.git
|
||||
GIT_TAG v7.0.3
|
||||
)
|
||||
FetchContent_Declare(
|
||||
cifpp
|
||||
${EXLC}
|
||||
GIT_REPOSITORY https://github.com/pdb-redo/libcifpp.git
|
||||
GIT_TAG v7.0.3
|
||||
)
|
||||
|
||||
FetchContent_MakeAvailable(cifpp)
|
||||
FetchContent_MakeAvailable(cifpp)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
add_subdirectory(libdssp)
|
||||
|
||||
@@ -157,7 +157,7 @@ void writeDSSP(const dssp &dssp, std::ostream &os)
|
||||
std::time_t today = system_clock::to_time_t(system_clock::now());
|
||||
std::tm *tm = std::gmtime(&today);
|
||||
|
||||
std::string version = kVersionNumber;
|
||||
std::string version = klibdsspVersionNumber;
|
||||
if (version.length() < 10)
|
||||
version.insert(version.end(), 10 - version.length(), ' ');
|
||||
|
||||
@@ -877,8 +877,8 @@ void annotateDSSP(cif::datablock &db, const dssp &dssp, bool writeOther, bool wr
|
||||
software.emplace({
|
||||
{ "pdbx_ordinal", software.get_unique_id("") },
|
||||
{ "name", "dssp" },
|
||||
{ "version", kVersionNumber },
|
||||
{ "date", kRevisionDate },
|
||||
{ "version", klibdsspVersionNumber },
|
||||
{ "date", klibdsspRevisionDate },
|
||||
{ "classification", "model annotation" }
|
||||
});
|
||||
}
|
||||
|
||||
@@ -1,16 +1,18 @@
|
||||
find_package(Catch2 QUIET)
|
||||
if(NOT(Catch2_FOUND OR TARGET Catch2))
|
||||
find_package(Catch2 QUIET)
|
||||
|
||||
if(NOT Catch2_FOUND)
|
||||
include(FetchContent)
|
||||
if(NOT Catch2_FOUND)
|
||||
include(FetchContent)
|
||||
|
||||
FetchContent_Declare(
|
||||
Catch2
|
||||
GIT_REPOSITORY https://github.com/catchorg/Catch2.git
|
||||
GIT_TAG v2.13.9)
|
||||
FetchContent_Declare(
|
||||
Catch2
|
||||
GIT_REPOSITORY https://github.com/catchorg/Catch2.git
|
||||
GIT_TAG v2.13.9)
|
||||
|
||||
FetchContent_MakeAvailable(Catch2)
|
||||
FetchContent_MakeAvailable(Catch2)
|
||||
|
||||
set(Catch2_VERSION "2.13.9")
|
||||
set(Catch2_VERSION "2.13.9")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
add_executable(unit-test-dssp ${CMAKE_CURRENT_SOURCE_DIR}/unit-test-dssp.cpp ${PROJECT_SOURCE_DIR}/libdssp/src/dssp-io.cpp)
|
||||
|
||||
Reference in New Issue
Block a user