[PATCH] solaris: Support building on GNU Hurd

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



---

Hi,

Can this be applied to support building the Solaris module for GNU Hurd?
The change itself is basic portability (including the POSIX <poll.h> for
POLLIN etc. and optionally using the Solaris <sys/conf.h>), so maybe it
also helps some other systems.  I also verified it still builds on an
OpenIndiana install.

Thanks.

David

 configure.ac                 | 2 +-
 src/modules/module-solaris.c | 9 ++++++++-
 2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/configure.ac b/configure.ac
index da0bfcd..1f8a181 100644
--- a/configure.ac
+++ b/configure.ac
@@ -436,7 +436,7 @@ AM_CONDITIONAL([HAVE_EVDEV], [test "x$HAVE_EVDEV" = "x1"])
 AC_CHECK_HEADERS_ONCE([sys/prctl.h])
 
 # Solaris
-AC_CHECK_HEADERS_ONCE([sys/filio.h])
+AC_CHECK_HEADERS_ONCE([sys/conf.h sys/filio.h])
 
 # Windows
 AC_CHECK_HEADERS_ONCE([windows.h winsock2.h ws2tcpip.h])
diff --git a/src/modules/module-solaris.c b/src/modules/module-solaris.c
index fee69e7..f44bc7c 100644
--- a/src/modules/module-solaris.c
+++ b/src/modules/module-solaris.c
@@ -31,11 +31,18 @@
 #include <sys/ioctl.h>
 #include <sys/types.h>
 
+#ifdef HAVE_POLL_H
+#include <poll.h>
+#endif
+
 #include <signal.h>
 #include <stropts.h>
-#include <sys/conf.h>
 #include <sys/audio.h>
 
+#ifdef HAVE_SYS_CONF_H
+#include <sys/conf.h>
+#endif
+
 #include <pulse/mainloop-signal.h>
 #include <pulse/xmalloc.h>
 #include <pulse/timeval.h>
-- 
2.7.5



[Index of Archives]     [Linux Audio Users]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux