Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Undefined reference building ncurses on cygwin

Windows XP:

I ultimately wanted to install DDD (the debugger). Its not available in binary form for Windows. When I got its source and tried to configure it, it complained that no term caps library was present. So I acquire ncurses and got this after a mostly successfull build using Cygwin Terminal:

../lib/libncurses.a(lib_ttyflags.o)(.text+0x41):lib_ttyflags.c: undefined reference to `_nc_mingw_ioctl'
../lib/libncurses.a(lib_ttyflags.o)(.text+0xd1):lib_ttyflags.c: undefined reference to `_nc_mingw_ioctl'
like image 707
ScrollerBlaster Avatar asked Oct 19 '25 09:10

ScrollerBlaster


1 Answers

It works for me when I do this:

configure --enable-term-driver --enable-sp-funcs
make

The --enable-term-driver was needed for "mingw" (I tested on msys, but this should work equally well on cygwin), and --enable-term-driver requires --enable-sp-funcs.

          --enable-sp-funcs
                  compile-in  support  for  extended  functions which
                  accept  a  SCREEN  pointer,  reducing  the need for
                  juggling  the  global  SP  value  with set_term and
                  delscreen.

          --enable-term-driver
                  compile  with  terminal-driver. That is used in the
                  MinGW  port,  and (being somewhat more complicated)
                  is  an experimental alternative to the conventional
                  termlib   internals.  Currently,  it  requires  the
                  sp-funcs feature to be enabled.

See here: http://lists.gnu.org/archive/html/info-gnu/2011-02/msg00020.html

like image 142
NotKyon Avatar answered Oct 22 '25 05:10

NotKyon



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!