[PATCH] D134261: Fix Z3 version detection regexp
Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 23 12:28:16 PDT 2022
This revision was automatically updated to reflect the committed changes.
Closed by commit rG74f0b058f078: Fix Z3 version detection regexp (authored by stilriv, committed by Mikhail R. Gadelha <mikhail at igalia.com>).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D134261/new/
https://reviews.llvm.org/D134261
Files:
llvm/cmake/modules/FindZ3.cmake
Index: llvm/cmake/modules/FindZ3.cmake
===================================================================
--- llvm/cmake/modules/FindZ3.cmake
+++ llvm/cmake/modules/FindZ3.cmake
@@ -38,7 +38,7 @@
)
if(Z3_COMPILED)
- string(REGEX REPLACE "([0-9]*\\.[0-9]*\\.[0-9]*)" "\\1"
+ string(REGEX REPLACE "([0-9]+\\.[0-9]+\\.[0-9]+)" "\\1"
z3_version "${SRC_OUTPUT}")
set(Z3_VERSION_STRING ${z3_version} PARENT_SCOPE)
else()
@@ -90,17 +90,17 @@
# Z3 4.8.1+ has the version is in a public header.
file(STRINGS "${Z3_INCLUDE_DIR}/z3_version.h"
z3_version_str REGEX "^#define[\t ]+Z3_MAJOR_VERSION[\t ]+.*")
- string(REGEX REPLACE "^.*Z3_MAJOR_VERSION[\t ]+([0-9]).*$" "\\1"
+ string(REGEX REPLACE "^.*Z3_MAJOR_VERSION[\t ]+([0-9]+).*$" "\\1"
Z3_MAJOR "${z3_version_str}")
file(STRINGS "${Z3_INCLUDE_DIR}/z3_version.h"
z3_version_str REGEX "^#define[\t ]+Z3_MINOR_VERSION[\t ]+.*")
- string(REGEX REPLACE "^.*Z3_MINOR_VERSION[\t ]+([0-9]).*$" "\\1"
+ string(REGEX REPLACE "^.*Z3_MINOR_VERSION[\t ]+([0-9]+).*$" "\\1"
Z3_MINOR "${z3_version_str}")
file(STRINGS "${Z3_INCLUDE_DIR}/z3_version.h"
z3_version_str REGEX "^#define[\t ]+Z3_BUILD_NUMBER[\t ]+.*")
- string(REGEX REPLACE "^.*Z3_BUILD_NUMBER[\t ]+([0-9]).*$" "\\1"
+ string(REGEX REPLACE "^.*Z3_BUILD_NUMBER[\t ]+([0-9]+).*$" "\\1"
Z3_BUILD "${z3_version_str}")
set(Z3_VERSION_STRING ${Z3_MAJOR}.${Z3_MINOR}.${Z3_BUILD})
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D134261.462572.patch
Type: text/x-patch
Size: 1480 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220923/50592e7a/attachment.bin>
More information about the llvm-commits
mailing list