mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
build on Win32
This commit is contained in:
@@ -149,6 +149,7 @@ mrb_fd_cloexec(mrb_state *mrb, int fd)
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifndef _WIN32
|
||||
static int
|
||||
mrb_cloexec_pipe(mrb_state *mrb, int fildes[2])
|
||||
{
|
||||
@@ -175,7 +176,6 @@ mrb_pipe(mrb_state *mrb, int pipes[2])
|
||||
return ret;
|
||||
}
|
||||
|
||||
#ifndef _WIN32
|
||||
static int
|
||||
mrb_proc_exec(const char *pname)
|
||||
{
|
||||
@@ -670,6 +670,7 @@ mrb_io_read_data_pending(mrb_state *mrb, mrb_value io)
|
||||
return 0;
|
||||
}
|
||||
|
||||
#ifndef _WIN32
|
||||
static mrb_value
|
||||
mrb_io_s_pipe(mrb_state *mrb, mrb_value klass)
|
||||
{
|
||||
@@ -705,6 +706,7 @@ mrb_io_s_pipe(mrb_state *mrb, mrb_value klass)
|
||||
|
||||
return mrb_assoc_new(mrb, r, w);
|
||||
}
|
||||
#endif
|
||||
|
||||
static mrb_value
|
||||
mrb_io_s_select(mrb_state *mrb, mrb_value klass)
|
||||
@@ -987,7 +989,9 @@ mrb_init_io(mrb_state *mrb)
|
||||
mrb_define_class_method(mrb, io, "for_fd", mrb_io_s_for_fd, MRB_ARGS_ANY());
|
||||
mrb_define_class_method(mrb, io, "select", mrb_io_s_select, MRB_ARGS_ANY());
|
||||
mrb_define_class_method(mrb, io, "sysopen", mrb_io_s_sysopen, MRB_ARGS_ANY());
|
||||
#ifndef _WIN32
|
||||
mrb_define_class_method(mrb, io, "_pipe", mrb_io_s_pipe, MRB_ARGS_NONE());
|
||||
#endif
|
||||
|
||||
mrb_define_method(mrb, io, "initialize", mrb_io_initialize, MRB_ARGS_ANY()); /* 15.2.20.5.21 (x)*/
|
||||
mrb_define_method(mrb, io, "sync", mrb_io_sync, MRB_ARGS_NONE());
|
||||
|
||||
Reference in New Issue
Block a user