1999-01-19 23:59:39 -05:00
|
|
|
require 'mkmf'
|
|
|
|
|
2001-08-12 19:42:44 -04:00
|
|
|
if( ! $CPPFLAGS )
|
|
|
|
$CPPFLAGS = ""
|
|
|
|
end
|
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-02 09:10:27 -05:00
|
|
|
if have_header("curses") 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
|
2001-11-23 04:53:54 -05:00
|
|
|
for f in %w(isendwin ungetch beep getnstr wgetnstr doupdate flash deleteln wdeleteln keypad keyname init_color)
|
1998-01-16 07:13:05 -05:00
|
|
|
have_func(f)
|
|
|
|
end
|
|
|
|
create_makefile("curses")
|
|
|
|
end
|