Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Compile Curses.pm on 10.3 UNIX
I was just compiling the Curses perl module on my mac and found I needed to change two files to get it to work. First, copy hints/c-freebsd.ncurses.h to c-config.h, and add the following lines to the end of c-config.h:
 #undef instr
 #undef bool
Second, apply this patch to Curses.c by using the patch command, or just manually editing Perl_sv_isa to sv_isa as shown below.
*** Curses.c    Wed Jul 25 10:10:38 2001
--- Curses.fixed.c      Wed Sep  8 11:01:53 2004
***************
*** 273,277 ****
  int argnum;
  {
!     if (Perl_sv_isa(sv, "Curses::Window")) {
        WINDOW *ret = (WINDOW *)SvIV((SV*)SvRV(sv));
        return ret;
--- 273,277 ----
  int argnum;
  {
!     if (sv_isa(sv, "Curses::Window")) {
        WINDOW *ret = (WINDOW *)SvIV((SV*)SvRV(sv));
        return ret;
And that's it. Run perl Makefile.PL, make, and make install as usual.
    •    
  • Currently 2.75 / 5
  You rated: 1 / 5 (4 votes cast)
 
[4,971 views]  

Compile Curses.pm on 10.3 | 1 comments | Create New Account
Click here to return to the 'Compile Curses.pm on 10.3' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Compile Curses.pm on 10.3
Authored by: blackhelicopter on Sep 14, '04 07:42:42AM

Thank you, I was trying (and failing) to do that a few days ago.



[ Reply to This | # ]