summaryrefslogtreecommitdiff
path: root/ext/pty/extconf.rb
blob: ba2b44c70bc3123fb75a1202a55d83a4eb952aef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
require 'mkmf'

if /mswin32|mingw/ !~ RUBY_PLATFORM
  have_header("sys/stropts.h")
  have_func("setresuid")
  $CFLAGS << "-DHAVE_DEV_PTMX" if /cygwin/ === RUBY_PLATFORM
  if have_func("openpty") or
      have_func("_getpty") or
      have_func("ioctl")
    create_makefile('pty')
  end
end