aboutsummaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2015-12-07 15:24:41 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2015-12-07 15:24:41 +0000
commit813685c8e0fa11bb1458823d396079c9c3470c7a (patch)
treee621c6e36a94bc5dfdf621af6db56246d4e13aba /CMakeLists.txt
parentd1ec922203c121e45930b82d64900ec0d8f9ef13 (diff)
downloadrspamd-813685c8e0fa11bb1458823d396079c9c3470c7a.tar.gz
rspamd-813685c8e0fa11bb1458823d396079c9c3470c7a.zip
Add hyperscan initialization
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt5
1 files changed, 5 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 96118f12d..2088e2776 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -49,6 +49,10 @@ OPTION(ENABLE_SNOWBALL "Enable snowball stemmer [default: ON]"
OPTION(ENABLE_CLANG_PLUGIN "Enable clang static analysing plugin [default: OFF]" OFF)
OPTION(ENABLE_HYPERSCAN "Enable hyperscan for fast regexp processing [default: OFF]" OFF)
+
+IF (ENABLE_HYPERSCAN MATCHES "ON")
+ ENABLE_LANGUAGE(CXX)
+ENDIF()
# Build optimized code for following CPU (default i386)
#SET(CPU_TUNE "i686")
@@ -891,6 +895,7 @@ TRY_RUN(_CAN_RUN _CAN_COMPILE
CMAKE_FLAGS CMAKE_C_FLAGS="-pthread")
IF(_CAN_RUN EQUAL 1)
SET(HAVE_PTHREAD_PROCESS_SHARED 1 CACHE INTERNAL "")
+ SET(RSPAMD_REQUIRED_LIBRARIES "${RSPAMD_REQUIRED_LIBRARIES} -lpthread")
ENDIF(_CAN_RUN EQUAL 1)
IF(HAVE_PTHREAD_PROCESS_SHARED)
MESSAGE(STATUS "pthread_mutexattr_setpshared is supported")