chiark / gitweb /
sd-daemon.c: allow use of -lrt to be avoided
[elogind.git] / src / libsystemd-daemon / sd-daemon.c
index b1ff43132a3cc89a03fb3f68bc12c6ddeca233ea..9cc1c37b468ce6e8ee84a110c419dc49768fb7b2 100644 (file)
@@ -47,7 +47,7 @@
 #include <stddef.h>
 #include <limits.h>
 
-#if defined(__linux__)
+#if defined(__linux__) && !defined(SD_DAEMON_DISABLE_MQ)
 #  include <mqueue.h>
 #endif
 
@@ -387,7 +387,7 @@ _sd_export_ int sd_is_socket_unix(int fd, int type, int listening, const char *p
 }
 
 _sd_export_ int sd_is_mq(int fd, const char *path) {
-#if !defined(__linux__)
+#if !defined(__linux__) || defined(SD_DAEMON_DISABLE_MQ)
         return 0;
 #else
         struct mq_attr attr;