forked from Zilliqa/Zilliqa
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
41 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# Find LevelDB | ||
|
||
find_path( | ||
LEVELDB_INCLUDE_DIR | ||
NAMES leveldb/db.h | ||
DOC "LevelDB include directory" | ||
) | ||
|
||
find_library( | ||
LEVELDB_LIBRARY | ||
NAMES leveldb | ||
DOC "LevelDB library" | ||
) | ||
|
||
set(LEVELDB_INCLUDE_DIRS ${LEVELDB_INCLUDE_DIR}) | ||
set(LEVELDB_LIBRARIES ${LEVELDB_LIBRARY}) | ||
|
||
if (NOT BUILD_SHARED_LIBS AND APPLE) | ||
find_path(SNAPPY_INCLUDE_DIR snappy.h PATH_SUFFIXES snappy) | ||
find_library(SNAPPY_LIBRARY snappy) | ||
set(LEVELDB_INCLUDE_DIRS ${LEVELDB_INCLUDE_DIR} ${SNAPPY_INCLUDE_DIR}) | ||
set(LEVELDB_LIBRARIES ${LEVELDB_LIBRARY} ${SNAPPY_LIBRARY}) | ||
endif() | ||
|
||
include(FindPackageHandleStandardArgs) | ||
find_package_handle_standard_args(leveldb DEFAULT_MSG | ||
LEVELDB_LIBRARY LEVELDB_INCLUDE_DIR) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
add_library (Database LevelDB.cpp MemoryDB.cpp OverlayDB.cpp) | ||
target_include_directories (Database PUBLIC ${PROJECT_SOURCE_DIR}/src) | ||
target_link_libraries (Database PUBLIC Common ${LevelDB_LIBRARIES} ${SNAPPY_LIBRARIES} Utils) | ||
target_link_libraries (Database PUBLIC Common ${LEVELDB_LIBRARIES} Utils Threads::Threads) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
include_directories(${Boost_INCLUDE_DIRS}) | ||
add_library (Utils DataConversion.cpp Logger.cpp SanityChecks.cpp Scheduler.cpp TimeUtils.cpp TxnRootComputationLight.cpp) | ||
target_include_directories (Utils PUBLIC ${PROJECT_SOURCE_DIR}/src Crypto) | ||
add_library(Utils DataConversion.cpp Logger.cpp SanityChecks.cpp Scheduler.cpp TimeUtils.cpp TxnRootComputationLight.cpp) | ||
target_include_directories(Utils PUBLIC ${PROJECT_SOURCE_DIR}/src Crypto Boost) | ||
target_link_libraries(Utils INTERFACE Threads::Threads) |