aboutsummaryrefslogtreecommitdiffstats
path: root/cmake/modules/FindGCRYPT.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake/modules/FindGCRYPT.cmake')
-rw-r--r--cmake/modules/FindGCRYPT.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/cmake/modules/FindGCRYPT.cmake b/cmake/modules/FindGCRYPT.cmake
index dc12485248..50c47590c3 100644
--- a/cmake/modules/FindGCRYPT.cmake
+++ b/cmake/modules/FindGCRYPT.cmake
@@ -37,7 +37,7 @@ find_library(GCRYPT_ERROR_LIBRARY
# Try to retrieve version from header if found (available since libgcrypt 1.3.0)
if(GCRYPT_INCLUDE_DIR)
- set(_version_regex "^#define[ \t]+GCRYPT_VERSION[ \t]+\"([^\"]+)\".*")
+ set(_version_regex "^#define[ \t]+GCRYPT_VERSION[ \t]+\"([0-9\.]+\.[0-9]+).*")
file(STRINGS "${GCRYPT_INCLUDE_DIR}/gcrypt.h" GCRYPT_VERSION REGEX "${_version_regex}")
string(REGEX REPLACE "${_version_regex}" "\\1" GCRYPT_VERSION "${GCRYPT_VERSION}")
unset(_version_regex)