1
mirror of https://github.com/jedisct1/libsodium.git synced 2024-12-20 02:25:14 -07:00
This commit is contained in:
Frank Denis 2019-07-23 22:29:52 +02:00
parent fbd47e868c
commit 3f27018394

View File

@ -210,10 +210,8 @@ if(sodium_INCLUDE_DIR)
set(_VERSION_HEADER "${sodium_INCLUDE_DIR}/sodium/version.h")
if(EXISTS "${_VERSION_HEADER}")
file(READ "${_VERSION_HEADER}" _VERSION_HEADER_CONTENT)
string(
REGEX
REPLACE
".*define[ \t]+SODIUM_VERSION_STRING[^\"]+\"([^\"]+)\".*"
string(REGEX
REPLACE ".*define[ \t]+SODIUM_VERSION_STRING[^\"]+\"([^\"]+)\".*"
"\\1"
sodium_VERSION_STRING
"${_VERSION_HEADER_CONTENT}")