1999-01-19 23:59:39 -05:00
|
|
|
require 'mkmf'
|
|
|
|
|
2001-12-31 12:48:33 -05:00
|
|
|
dir_config('curses')
|
|
|
|
dir_config('ncurses')
|
|
|
|
dir_config('termcap')
|
2001-02-18 03:18:47 -05:00
|
|
|
|
1999-08-13 01:37:52 -04:00
|
|
|
make=false
|
2000-05-13 12:13:31 -04:00
|
|
|
have_library("mytinfo", "tgetent") if /bow/ =~ RUBY_PLATFORM
|
1998-01-16 07:13:05 -05:00
|
|
|
if have_header("ncurses.h") and have_library("ncurses", "initscr")
|
1999-08-13 01:37:52 -04:00
|
|
|
make=true
|
1998-01-16 07:13:05 -05:00
|
|
|
elsif have_header("ncurses/curses.h") and have_library("ncurses", "initscr")
|
1999-08-13 01:37:52 -04:00
|
|
|
make=true
|
|
|
|
elsif have_header("curses_colr/curses.h") and have_library("cur_colr", "initscr")
|
|
|
|
make=true
|
1998-01-16 07:13:05 -05:00
|
|
|
else
|
|
|
|
have_library("termcap", "tgetent")
|
2001-12-04 00:27:26 -05:00
|
|
|
if have_header("curses.h") and have_library("curses", "initscr")
|
1999-08-13 01:37:52 -04:00
|
|
|
make=true
|
1998-01-16 07:13:05 -05:00
|
|
|
end
|
|
|
|
end
|
|
|
|
|
1999-08-13 01:37:52 -04:00
|
|
|
if make
|
2002-01-29 14:24:43 -05:00
|
|
|
for f in %w(isendwin ungetch beep getnstr wgetnstr doupdate flash deleteln wdeleteln keypad keyname init_color wresize resizeterm)
|
1998-01-16 07:13:05 -05:00
|
|
|
have_func(f)
|
|
|
|
end
|
|
|
|
create_makefile("curses")
|
|
|
|
end
|