You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

36 lines
1.2 KiB

From: =?utf-8?q?Ond=C5=99ej_Sur=C3=BD?= <ondrej@debian.org>
Date: Wed, 22 Nov 2017 06:05:45 +0000
Subject: Revert to using system pcre library
---
cmake/pcre.cmake | 16 ++--------------
1 file changed, 2 insertions(+), 14 deletions(-)
--- a/cmake/pcre.cmake
+++ b/cmake/pcre.cmake
@@ -1,23 +1,11 @@
-INCLUDE (CheckCSourceRuns)
-
SET(WITH_PCRE "auto" CACHE STRING
"Which pcre to use (possible values are 'bundled', 'system', or 'auto')")
MACRO (CHECK_PCRE)
IF(WITH_PCRE STREQUAL "system" OR WITH_PCRE STREQUAL "auto")
- CHECK_LIBRARY_EXISTS(pcre pcre_stack_guard "" HAVE_PCRE_STACK_GUARD)
- IF(NOT CMAKE_CROSSCOMPILING)
- SET(CMAKE_REQUIRED_LIBRARIES "pcre")
- CHECK_C_SOURCE_RUNS("
- #include <pcre.h>
- int main() {
- return -pcre_exec(NULL, NULL, NULL, -999, -999, 0, NULL, 0) < 256;
- }" PCRE_STACK_SIZE_OK)
- SET(CMAKE_REQUIRED_LIBRARIES)
- ENDIF()
+ CHECK_LIBRARY_EXISTS(pcre pcre_stack_guard "" HAVE_PCRE)
ENDIF()
- IF(NOT HAVE_PCRE_STACK_GUARD OR NOT PCRE_STACK_SIZE_OK OR
- WITH_PCRE STREQUAL "bundled")
+ IF(NOT HAVE_PCRE OR WITH_PCRE STREQUAL "bundled")
IF (WITH_PCRE STREQUAL "system")
MESSAGE(FATAL_ERROR "system pcre is not found or unusable")
ENDIF()