summaryrefslogtreecommitdiff
path: root/io.c
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-08-06 20:52:44 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-08-06 20:52:44 +0000
commit48e21d2051ea39b073c204f0359e2778ab9660e2 (patch)
treea87024f988f543cb81a6076a3987ccd32c934019 /io.c
parent403d0334c16d9f854ef1ae97de1ae76cfe26fd7c (diff)
* eval_intern.h: Add support to Haiku. see [ruby-core:18110]
* include/ruby/defines.h: ditto. * configure.in: ditto. * thread_pthread.c: ditto. * io.c: ditto. * lib/mkmf.rb: ditto. * ext/socket/getaddrinfo.c: ditto. * ext/socket/extconf.rb: ditto. * ext/socket/socket.c: ditto. * ext/socket/addrinfo.h: ditto. * ext/socket/getnameinfo.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18402 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r--io.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/io.c b/io.c
index 7925c7b5e4..ed3023b190 100644
--- a/io.c
+++ b/io.c
@@ -26,7 +26,7 @@
#include <sys/types.h>
#if !defined(_WIN32) && !defined(__DJGPP__)
-# if defined(__BEOS__)
+#if defined(__BEOS__) && !defined(__HAIKU__)
# include <net/socket.h>
# else
# include <sys/socket.h>
@@ -90,7 +90,6 @@ extern void Init_File(void);
# ifndef NOFILE
# define NOFILE (OPEN_MAX)
# endif
-#include <net/socket.h>
#endif
#include "ruby/util.h"
@@ -202,6 +201,10 @@ static int max_file_descriptor = NOFILE;
# endif
#endif
+#if defined(__HAIKU__)
+#define shutdown(a,b) 0
+#endif
+
#if defined(_WIN32)
#define is_socket(fd, path) rb_w32_is_socket(fd)
#elif !defined(S_ISSOCK)