Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Why is the Curses module broken? I can't get it to compile under RedHat 8.0 for love or money - CPAN fails at compile time and a source install fails thusly:
gcc -c -I/usr/include/ncurses -D_REENTRANT -D_GNU_SOURCE -fno-strict- +aliasing -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gd +bm -O2 -march=i386 -mcpu=i686 -DVERSION=\"1.06\" -DXS_VERSION=\"1.0 +6\" -fpic "-I/usr/lib/perl5/5.8.0/i386-linux-thread-multi/CORE" Cur +ses.c In file included from /usr/lib/perl5/5.8.0/i386-linux-thread-multi/COR +E/perl.h:1713, from Curses.c:14: /usr/lib/perl5/5.8.0/i386-linux-thread-multi/CORE/handy.h:83:1: warnin +g: "bool" redefined In file included from c-config.h:9, from Curses.c:11: /usr/include/ncurses/curses.h:117:1: warning: this is the location of +the previous definition Curses.c: In function `c_sv2window': Curses.c:275: warning: passing arg 1 of `Perl_sv_isa' from incompatibl +e pointer type Curses.c:275: warning: passing arg 2 of `Perl_sv_isa' from incompatibl +e pointer type Curses.c:275: too few arguments to function `Perl_sv_isa' In file included from Curses.c:344: CursesFun.c: In function `XS_Curses_newterm': CursesFun.c:1279: warning: initialization from incompatible pointer ty +pe CursesFun.c:1280: warning: initialization from incompatible pointer ty +pe CursesFun.c: In function `XS_Curses_putwin': CursesFun.c:3453: warning: initialization from incompatible pointer ty +pe CursesFun.c: In function `XS_Curses_getwin': CursesFun.c:3472: warning: initialization from incompatible pointer ty +pe make: *** [Curses.o] Error 1

Is anyone maintaining this module? Has it been supeceded by something? I tried a patch I found on the support forum here, but it didn't work either. Help, please?

Replies are listed 'Best First'.
Re: Cursed by Curses
by Zaxo (Archbishop) on Mar 24, 2003 at 06:06 UTC

    Was the patch you mentioned from Build Curses for Perl 5.8.0? That one has worked for several monks. Your error messages are what I expect if those patches have not been applied.

    I really should send them to the Curses maintainer, but I'll wait to see how you do with them.

    After Compline,
    Zaxo

      First of all, many thanks for responding to my rather, um, terse question. I have an account now, since I'm knee deep in Perl code - I'll likley be posting quite a bit.

      Anyways, yes, the patches in that link are the ones I applied. Actually, the linux patch utility failed on me when I went to apply them to the source of Curses - the patch to CursesFun.c errored out for some reason. I tried to hand apply the patch to the file, but that didn't work either (though I couldn't see why for the life of me). I'll try it again, and report the error that patch throws.

      Once more, thanks!

      Soko