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.

42 lines
1.4 KiB

9 years ago
set(CMAKE_INCLUDE_CURRENT_DIR ON)
8 years ago
set(SOURCES "daemon.c" "strlcpy.c" "config.c" "log.c" "matches.c" "ipaddr.c" "source.c" "filter.c" "backend.c" "jail.c")
9 years ago
if (WITH_CSOCKET)
list(APPEND SOURCES "commands.c" "csocket.c" "cmsg.c")
9 years ago
add_definitions("-DWITH_CSOCKET")
endif ()
add_executable("f2b" ${SOURCES})
9 years ago
install(TARGETS "f2b" RUNTIME DESTINATION ${CMAKE_INSTALL_SBINDIR})
9 years ago
if (WITH_CLIENT)
set(SOURCES "strlcpy.c" "log.c" "client.c" "cmsg.c" "commands.c" "csocket.c")
add_executable("f2bc" ${SOURCES})
install(TARGETS "f2bc" RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
9 years ago
endif ()
set(SOURCES "strlcpy.c" "source-test.c" "log.c" "config.c" "source.c")
add_executable("f2b-source-test" ${SOURCES})
9 years ago
set(SOURCES "strlcpy.c" "filter-test.c" "log.c" "config.c" "filter.c")
add_executable("f2b-filter-test" ${SOURCES})
set(SOURCES "strlcpy.c" "backend-test.c" "log.c" "config.c" "backend.c")
add_executable("f2b-backend-test" ${SOURCES})
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(f2b "dl")
target_link_libraries("f2b-source-test" "dl")
target_link_libraries("f2b-filter-test" "dl")
target_link_libraries("f2b-backend-test" "dl")
endif ()
install(TARGETS "f2b-source-test" "f2b-filter-test" "f2b-backend-test"
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
9 years ago
add_subdirectory("backends")
add_subdirectory("filters")
add_subdirectory("sources")