diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2020-06-01 15:35:03 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2020-06-01 15:35:03 +0100 |
commit | b488a309f514fecf7cda9bb5ccb53803a5034210 (patch) | |
tree | 02529a5a7543b4928df5bfb2ba1e86637f2c8a41 | |
parent | 7e9966c5a2fa5d9dd56c3c4b4a123bfbeb020196 (diff) | |
download | rspamd-b488a309f514fecf7cda9bb5ccb53803a5034210.tar.gz rspamd-b488a309f514fecf7cda9bb5ccb53803a5034210.zip |
[Minor] Add recvmmsg detection
-rw-r--r-- | CMakeLists.txt | 5 | ||||
-rw-r--r-- | config.h.in | 1 |
2 files changed, 6 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index e60b9cf84..0af33f1fe 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -505,6 +505,11 @@ IF(CMAKE_SYSTEM_NAME STREQUAL "Linux") # on a build system. On the other hand, we know that linux has stupid # but compatible shmem support, so we assume this macro as true SET(HAVE_SANE_SHMEM 1) + CHECK_C_SOURCE_COMPILES ("#define _GNU_SOURCE + #include <sys/socket.h> + int main (int argc, char **argv) { + return ((int*)(&recvmmsg))[argc]; + }" HAVE_RECVMMSG) ELSE() CHECK_C_SOURCE_RUNS(" #include <sys/mman.h> diff --git a/config.h.in b/config.h.in index 013a0873c..adb799864 100644 --- a/config.h.in +++ b/config.h.in @@ -83,6 +83,7 @@ #cmakedefine HAVE_PWD_H 1 #cmakedefine HAVE_RDTSC 1 #cmakedefine HAVE_READPASSPHRASE_H 1 +#cmakedefine HAVE_RECVMMSG 1 #cmakedefine HAVE_RUSAGE_SELF 1 #cmakedefine HAVE_SA_SIGINFO 1 #cmakedefine HAVE_SANE_SHMEM 1 |