diff --git a/ext/standard/proc_open.c b/ext/standard/proc_open.c index e463e2515718d..94099b7101865 100644 --- a/ext/standard/proc_open.c +++ b/ext/standard/proc_open.c @@ -47,8 +47,13 @@ # if HAVE_PTY_H # include # else -/* Mac OS X defines `openpty` in */ -# include +# if defined(__FreeBSD__) +/* FreeBSD defines `openpty` in */ +# include +# else +/* Mac OS X and some BSD defines `openpty` in */ +# include +# endif # endif #endif