Skip to content

Commit

Permalink
update cmake version
Browse files Browse the repository at this point in the history
  • Loading branch information
yc1111 committed Jan 31, 2024
1 parent 8cdeaae commit abc4222
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
CMAKE_MINIMUM_REQUIRED(VERSION 2.8)
CMAKE_MINIMUM_REQUIRED(VERSION 3.12)

PROJECT(ledgebase)

Expand Down
12 changes: 6 additions & 6 deletions cmake/Modules/FindCryptoPP.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ FIND_LIBRARY (CRYPTOPP_LIBRARY_RELEASE
IF (CRYPTOPP_LIBRARY_DEBUG AND CRYPTOPP_LIBRARY_RELEASE)
SET (CRYPTOPP_LIBRARY
optimized ${CRYPTOPP_LIBRARY_RELEASE}
debug ${CRYPTOPP_LIBRARY_DEBUG} CACHE DOC "CryptoPP library")
debug ${CRYPTOPP_LIBRARY_DEBUG} CACHE STRING "CryptoPP library")
ELSEIF (CRYPTOPP_LIBRARY_RELEASE)
SET (CRYPTOPP_LIBRARY ${CRYPTOPP_LIBRARY_RELEASE} CACHE DOC
SET (CRYPTOPP_LIBRARY ${CRYPTOPP_LIBRARY_RELEASE} CACHE STRING
"CryptoPP library")
ENDIF (CRYPTOPP_LIBRARY_DEBUG AND CRYPTOPP_LIBRARY_RELEASE)

Expand All @@ -42,14 +42,14 @@ IF (CRYPTOPP_INCLUDE_DIR)

STRING (REGEX REPLACE
"^#define CRYPTOPP_VERSION[ \t]+([0-9]+)" "\\1" _CRYPTOPP_VERSION_TMP
${_CRYPTOPP_VERSION_TMP})
"${_CRYPTOPP_VERSION_TMP}")

STRING (REGEX REPLACE "([0-9]+)[0-9][0-9]" "\\1" CRYPTOPP_VERSION_MAJOR
${_CRYPTOPP_VERSION_TMP})
"${_CRYPTOPP_VERSION_TMP}")
STRING (REGEX REPLACE "[0-9]([0-9])[0-9]" "\\1" CRYPTOPP_VERSION_MINOR
${_CRYPTOPP_VERSION_TMP})
"${_CRYPTOPP_VERSION_TMP}")
STRING (REGEX REPLACE "[0-9][0-9]([0-9])" "\\1" CRYPTOPP_VERSION_PATCH
${_CRYPTOPP_VERSION_TMP})
"${_CRYPTOPP_VERSION_TMP}")

SET (CRYPTOPP_VERSION_COUNT 3)
SET (CRYPTOPP_VERSION
Expand Down
2 changes: 1 addition & 1 deletion cmake/Modules/FindLibEvent.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ set (LIBEVENT_LIBRARIES
${LIBEVENT_EXTRA}
${LIBEVENT_THREAD}
${LIBEVENT_EXTRA})
find_package_handle_standard_args (LIBEVENT DEFAULT_MSG LIBEVENT_LIBRARIES LIBEVENT_INCLUDE_DIR)
find_package_handle_standard_args (LibEvent DEFAULT_MSG LIBEVENT_LIBRARIES LIBEVENT_INCLUDE_DIR)
mark_as_advanced(LIBEVENT_INCLUDE_DIRS LIBEVENT_LIBRARIES)

if (LIBEVENT_FOUND)
Expand Down
2 changes: 1 addition & 1 deletion cmake/Modules/FindRocksdb.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FIND_PATH(ROCKSDB_INCLUDE_DIR NAMES rocksdb/db.h PATHS "$ENV{ROCKSDB_DIR}/includ
FIND_LIBRARY(ROCKSDB_LIBRARIES NAMES rocksdb PATHS "$ENV{ROCKSDB_DIR}/lib")

INCLUDE(FindPackageHandleStandardArgs)
find_package_handle_standard_args(ROCKSDB DEFAULT_MSG ROCKSDB_INCLUDE_DIR ROCKSDB_LIBRARIES)
find_package_handle_standard_args(Rocksdb DEFAULT_MSG ROCKSDB_INCLUDE_DIR ROCKSDB_LIBRARIES)

IF(ROCKSDB_FOUND)
MESSAGE(STATUS "Found Rocksdb at ${ROCKSDB_INCLUDE_DIR}")
Expand Down

0 comments on commit abc4222

Please sign in to comment.