]> source.dussan.org Git - rspamd.git/commitdiff
[Fix] Avoid linking with actrie if hyperscan is enabled
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Sat, 25 Jun 2016 12:39:35 +0000 (13:39 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Sat, 25 Jun 2016 12:39:35 +0000 (13:39 +0100)
CMakeLists.txt
src/rspamadm/CMakeLists.txt

index 84a3f50057e86adff18a2db27ba50588947f4918..4d1f8cf94a05cf95b1d993d0136aa15399e5b657 100644 (file)
@@ -1109,6 +1109,7 @@ IF(GLIB_COMPAT)
        LIST(APPEND RSPAMD_REQUIRED_LIBRARIES glibadditions)
 ENDIF(GLIB_COMPAT)
 
+
 ADD_SUBDIRECTORY(contrib/xxhash)
 ADD_SUBDIRECTORY(contrib/cdb)
 ADD_SUBDIRECTORY(contrib/http-parser)
@@ -1124,6 +1125,16 @@ ADD_SUBDIRECTORY(contrib/aho-corasick)
 ADD_SUBDIRECTORY(contrib/lpeg)
 ADD_SUBDIRECTORY(contrib/linenoise)
 
+IF (ENABLE_SNOWBALL MATCHES "ON")
+       LIST(APPEND RSPAMD_REQUIRED_LIBRARIES stemmer)
+ENDIF()
+IF(ENABLE_HIREDIS MATCHES "ON")
+       LIST(APPEND RSPAMD_REQUIRED_LIBRARIES rspamd-hiredis)
+ENDIF()
+IF(ENABLE_HYPERSCAN MATCHES "OFF")
+       LIST(APPEND RSPAMD_REQUIRED_LIBRARIES rspamd-actrie)
+ENDIF()
+
 IF(ENABLE_CLANG_PLUGIN MATCHES "ON")
        ADD_SUBDIRECTORY(clang-plugin)
 ENDIF()
index 992e2a3aaef50e10e887ff6e8beb3631c4d99e6c..8189598eda9bbfc22961e255b75159c18844f400 100644 (file)
@@ -36,14 +36,6 @@ ADD_EXECUTABLE(rspamadm ${RSPAMADMSRC})
 ADD_DEPENDENCIES(rspamadm rspamadm_lua_preprocess)
 TARGET_LINK_LIBRARIES(rspamadm rspamd-server)
 TARGET_LINK_LIBRARIES(rspamadm ${RSPAMD_REQUIRED_LIBRARIES})
-
-IF (ENABLE_SNOWBALL MATCHES "ON")
-    TARGET_LINK_LIBRARIES(rspamadm stemmer)
-ENDIF()
-IF(ENABLE_HIREDIS MATCHES "ON")
-       TARGET_LINK_LIBRARIES(rspamadm rspamd-hiredis)
-ENDIF()
-TARGET_LINK_LIBRARIES(rspamadm rspamd-actrie)
 TARGET_LINK_LIBRARIES(rspamadm rspamd-linenoise)
 
 IF (NOT DEBIAN_BUILD)