From 29cd166fe5e29eba6537fd7a2c41041afa1de1af Mon Sep 17 00:00:00 2001 From: Colin LeMahieu Date: Sun, 17 Sep 2023 18:44:29 +0100 Subject: [PATCH] Creating a new library nano_store to hold datastore related functionality. Created nano_store library which is under 'store' Moving store.cpp to component.cpp --- CMakeLists.txt | 3 +++ nano/node/CMakeLists.txt | 1 + nano/secure/CMakeLists.txt | 2 -- nano/store/CMakeLists.txt | 14 ++++++++++++++ nano/{secure/store.cpp => store/component.cpp} | 0 5 files changed, 18 insertions(+), 2 deletions(-) create mode 100644 nano/store/CMakeLists.txt rename nano/{secure/store.cpp => store/component.cpp} (100%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 645c59b4..c8cd2ec4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -651,6 +651,9 @@ target_compile_definitions(blake2 PRIVATE -D__SSE2__) add_subdirectory(nano/crypto_lib) add_subdirectory(nano/secure) +add_subdirectory(nano/store) +target_include_directories(nano_store PUBLIC ${BOOST_LIBRARY_INCLUDES}) +target_include_directories(nano_store PUBLIC submodules) add_subdirectory(nano/lib) add_subdirectory(nano/node) add_subdirectory(nano/nano_node) diff --git a/nano/node/CMakeLists.txt b/nano/node/CMakeLists.txt index d077a747..9e770f92 100644 --- a/nano/node/CMakeLists.txt +++ b/nano/node/CMakeLists.txt @@ -263,6 +263,7 @@ target_link_libraries( rpc secure nano_lib + nano_store libminiupnpc-static argon2 lmdb diff --git a/nano/secure/CMakeLists.txt b/nano/secure/CMakeLists.txt index af15d0bd..5942304e 100644 --- a/nano/secure/CMakeLists.txt +++ b/nano/secure/CMakeLists.txt @@ -39,7 +39,6 @@ add_library( ${PLATFORM_SECURE_SOURCE} ${CMAKE_BINARY_DIR}/bootstrap_weights_live.cpp ${CMAKE_BINARY_DIR}/bootstrap_weights_beta.cpp - store.cpp buffer.hpp common.hpp common.cpp @@ -58,7 +57,6 @@ target_link_libraries( nano_lib ed25519 crypto_lib - lmdb Boost::iostreams Boost::system Boost::filesystem) diff --git a/nano/store/CMakeLists.txt b/nano/store/CMakeLists.txt new file mode 100644 index 00000000..af1b0f44 --- /dev/null +++ b/nano/store/CMakeLists.txt @@ -0,0 +1,14 @@ +add_library(nano_store component.cpp component.hpp) + +target_link_libraries( + nano_store + Boost::circular_buffer + Boost::endian + Boost::filesystem + Boost::iostreams + Boost::log_setup + Boost::log + Boost::multiprecision + Boost::pool + Boost::stacktrace + Boost::variant) diff --git a/nano/secure/store.cpp b/nano/store/component.cpp similarity index 100% rename from nano/secure/store.cpp rename to nano/store/component.cpp