Skip to content
Snippets Groups Projects
Commit 955e1b57 authored by Jason Volk's avatar Jason Volk
Browse files

Fix Findsodium.cmake version test.

parent 67d39691
No related branches found
No related tags found
No related merge requests found
......@@ -213,12 +213,12 @@ endif()
# extract sodium version
if (sodium_INCLUDE_DIR)
set(_VERSION_HEADER "${_INCLUDE_DIR}/sodium/version.h")
if (EXISTS _VERSION_HEADER)
set(_VERSION_HEADER "${sodium_INCLUDE_DIR}/sodium/version.h")
if (EXISTS "${_VERSION_HEADER}")
file(READ "${_VERSION_HEADER}" _VERSION_HEADER_CONTENT)
string(REGEX REPLACE ".*#[ \t]*define[ \t]*SODIUM_VERSION_STRING[ \t]*\"([^\n]*)\".*" "\\1"
sodium_VERSION "${_VERSION_HEADER_CONTENT}")
set(sodium_VERSION "${sodium_VERSION}" PARENT_SCOPE)
set(sodium_VERSION "${sodium_VERSION}")
endif()
endif()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment