diff options
author | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2011-05-11 19:11:05 +0400 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2011-05-11 19:11:05 +0400 |
commit | f7595acb30071eb5001b629f47f5606ea07e2a5a (patch) | |
tree | c4d588ff6e3e448b654ee1f7f628ea1757efb319 | |
parent | bc953ee7602b6a4278fc5c13a83ad570444f5cc6 (diff) | |
download | rspamd-f7595acb30071eb5001b629f47f5606ea07e2a5a.tar.gz rspamd-f7595acb30071eb5001b629f47f5606ea07e2a5a.zip |
Fix dependencies in cmake.
-rw-r--r-- | CMakeLists.txt | 9 | ||||
-rw-r--r-- | lib/CMakeLists.txt | 7 | ||||
-rw-r--r-- | utils/statshow/CMakeLists.txt | 1 |
3 files changed, 11 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index bbe628dd5..cbddacb6f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -563,6 +563,10 @@ SET(PLUGINSSRC src/plugins/surbl.c src/plugins/fuzzy_check.c src/plugins/spf.c) +ADD_CUSTOM_COMMAND(OUTPUT src/modules.c + COMMAND ../utils/gen-modules.sh ${PLUGINSSRC} + WORKING_DIRECTORY src) + ADD_SUBDIRECTORY(src/lua) ADD_SUBDIRECTORY(src/json) ADD_SUBDIRECTORY(src/cdb) @@ -578,9 +582,7 @@ LIST(LENGTH PLUGINSSRC RSPAMD_MODULES_NUM) ############################ TARGETS SECTION ############################### -ADD_CUSTOM_COMMAND(OUTPUT src/modules.c - COMMAND ../utils/gen-modules.sh ${PLUGINSSRC} - WORKING_DIRECTORY src) + CONFIGURE_FILE(config.h.in src/config.h) CONFIGURE_FILE(contrib/exim/local_scan.c.in contrib/exim/local_scan_rspamd.c @ONLY) @@ -588,7 +590,6 @@ CONFIGURE_FILE(rspamd.xml.sample conf/rspamd.xml.sample @ONLY) ######################### LINK SECTION ############################### - ADD_EXECUTABLE(rspamd ${RSPAMDSRC} ${CONTRIBSRC} ${TOKENIZERSSRC} ${CLASSIFIERSSRC} ${PLUGINSSRC}) SET_TARGET_PROPERTIES(rspamd PROPERTIES LINKER_LANGUAGE C) diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 951551e62..2fdf37904 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -64,4 +64,9 @@ SET_TARGET_PROPERTIES(rspamdserver PROPERTIES LINKER_LANGUAGE C) SET_TARGET_PROPERTIES(rspamdserver PROPERTIES COMPILE_FLAGS "-DRSPAMD_LIB") TARGET_LINK_LIBRARIES(rspamdserver rspamd_lua) TARGET_LINK_LIBRARIES(rspamdserver rspamd_json) -TARGET_LINK_LIBRARIES(rspamdserver rspamd_cdb)
\ No newline at end of file +TARGET_LINK_LIBRARIES(rspamdserver rspamd_cdb) + +ADD_CUSTOM_TARGET(genmodules + COMMAND ../utils/gen-modules.sh ${PLUGINSSRC} + WORKING_DIRECTORY src) +ADD_DEPENDENCIES(rspamdserver genmodules)
\ No newline at end of file diff --git a/utils/statshow/CMakeLists.txt b/utils/statshow/CMakeLists.txt index 2e28d019e..bf3308814 100644 --- a/utils/statshow/CMakeLists.txt +++ b/utils/statshow/CMakeLists.txt @@ -2,7 +2,6 @@ SET(STATSHOWSRC statshow.c) FOREACH(_rs ${CLASSIFIERSSRC} ${TOKENIZERSSRC}) LIST(APPEND STATSHOWSRC "../../${_rs}") - MESSAGE("${_rs}") ENDFOREACH(_rs) ADD_EXECUTABLE(statshow EXCLUDE_FROM_ALL ${STATSHOWSRC}) |