[submodule "src/third-party/singleapplication"]
path = src/third-party/singleapplication
url = https://github.com/itay-grudev/SingleApplication.git
+[submodule "src/third-party/polyseed"]
+ path = src/third-party/polyseed
+ url = https://github.com/tevador/polyseed.git
# Polyseed 16 word mnemonic seeds
find_package(Polyseed REQUIRED)
+if(Polyseed_SUBMODULE)
+ add_subdirectory(src/third-party/polyseed)
+endif()
# libzip
find_package(zlib CONFIG)
find_path(POLYSEED_INCLUDE_DIR polyseed.h)
-message(STATUS "POLYSEED PATH ${POLYSEED_INCLUDE_DIR}")
-
find_library(POLYSEED_LIBRARY polyseed)
+if (NOT POLYSEED_INCLUDE_DIR OR NOT POLYSEED_LIBRARY)
+ MESSAGE(STATUS "Could not find installed Polyseed, using submodule instead")
+ set(Polyseed_SUBMODULE "ON")
+ set(POLYSEED_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/src/third-party/polyseed/include)
+ set(POLYSEED_LIBRARY polyseed)
+endif()
+message(STATUS "POLYSEED PATH ${POLYSEED_INCLUDE_DIR}")
message(STATUS "POLYSEED LIBARY ${POLYSEED_LIBRARY}")
\ No newline at end of file