Ncurses-ruby on cygwin

I am trying to install ncurses-ruby on cygwin, which all the docs
indicate should work just fine. when executing extconf.rb I get:

checking for unistd.h… yes
checking for /usr/include/ncurses.h… no
checking for ncurses/curses.h… no
checking for /usr/include/curses.h… no
./extconf.rb:35: ncurses header file not found (RuntimeError)

Even though the header file exists in /usr/include

I tried modifying extconf.rb to hard code in the absolute path but that
didn’t work… what do I need to do to get this to work?

culley

I am trying to install ncurses-ruby on cygwin, which all the docs
indicate should work just fine.

Yes. Last time I tried, it did work.

when executing extconf.rb I get:

checking for unistd.h... yes
checking for /usr/include/ncurses.h... no
checking for ncurses/curses.h... no
checking for /usr/include/curses.h... no
./extconf.rb:35: ncurses header file not found (RuntimeError)

Even though the header file exists in /usr/include

If it really exists in /usr/include, then it means your compiler does not
look there.

Maybe you are not using the ruby interpreter built by cygwin. You have to.
You cannot use cygwin to build ruby extensions for a ruby interpreter
built with another compiler.

Or you have multiple installations of cygwin.

Try executing extconf.rb as

/usr/local/bin/ruby extconf.rb

from your bash prompt.

  Tobias

···

On 24 Jun 2003, culley harrelson wrote:

If it really exists in /usr/include, then it means your compiler does not
look there.

Maybe you are not using the ruby interpreter built by cygwin. You have to.
You cannot use cygwin to build ruby extensions for a ruby interpreter
built with another compiler.

I have never installed with Win32 Native Ruby-- only Cygwin

Or you have multiple installations of cygwin.

Try executing extconf.rb as

/usr/local/bin/ruby extconf.rb

from your bash prompt.

Ruby was installed in /usr/bin rather than /usr/local/bin. This
installation was done using the cygwin setup.exe on June 8 so I am
fairly current. I have a sym link at /usr/local/bin/ruby because this
is where it is on my other systems…

culley

I did not know that cygwin has a ruby package by now. Nice.

What Error message do you get for

bash-2.05b$ cat >check.c
#include <ncurses.h>
int main;
bash-2.05b$ ruby -r rbconfig -e 'print Config::CONFIG["CC"], " ", Config::CONFIG["CFLAGS"]' check.c

(produce a check.c file that includes #<ncurses.h>; and try to compile
that file with the C compiler and CFLAGS that ruby knows of.)

Maybe the precompiled ruby from cygwin has problems. You could try to
recompile ruby yourself.

Tobias

···

On Tue, 24 Jun 2003, culley harrelson wrote

Ruby was installed in /usr/bin rather than /usr/local/bin. This
installation was done using the cygwin setup.exe on June 8 so I am
fairly current. I have a sym link at /usr/local/bin/ruby because this
is where it is on my other systems…

What Error message do you get for

bash-2.05b$ cat >check.c
#include <ncurses.h>
int main;
bash-2.05b$ ruby -r rbconfig -e 'print Config::CONFIG["CC"], " ", Config::CONFIG["CFLAGS"]' check.c

(produce a check.c file that includes #<ncurses.h>; and try to compile
that file with the C compiler and CFLAGS that ruby knows of.)

This produces:

check.c:1:21: ncurses.h: No such file or directory

ruby is using gcc… gcc check.c produces the same results so maybe it
has nothing to do with ruby?

Maybe the precompiled ruby from cygwin has problems. You could try to
recompile ruby yourself.

I am stuck in cygwin for another week or two and then I will be back on
a real unix box-- I will probably just wait.

culley

Hi,

···

At Tue, 24 Jun 2003 19:28:23 +0900, culley harrelson wrote:

check.c:1:21: ncurses.h: No such file or directory

You don’t install libncurses-devel package.


Nobu Nakada