bug-gdb
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: SGI IRIX - no nsig


From: David B Anderson
Subject: Re: SGI IRIX - no nsig
Date: Mon, 2 Oct 2000 09:35:04 -0700 (PDT)

>I have compiled gdb5.0 here on my IRIX 6.5 box, but I can't compile
>the current CVS version since there is no variable  nsig  anywhere
>in IRIX's headers.
>
>What can I do?

You don't show the exact message. 

The build of expect with top of trunk gdb fails on IRIX 6.5

gcc -c  -I. -I../../gdbtot/src/expect -I/xlv0/davea/gdbtot/src/tcl/generic 
-I/xlv0/davea/gdbtot/src/tk/generic  -DEXP_VERSION=\"5.26\" 
-DSCRIPTDIR=\"/usr/local/share\" -DEXECSCRIPTDIR=\"/usr/local/lib/expect5.26\" 
-DTCL_DEBUGGER -g -O2   -DDFLT_STTY="\"sane\""  
../../gdbtot/src/expect/exp_command.c
../../gdbtot/src/expect/exp_command.c: In function `Exp_SpawnCmd':
../../gdbtot/src/expect/exp_command.c:686: `NSIG' undeclared (first use in this
function)
../../gdbtot/src/expect/exp_command.c:686: (Each undeclared identifier is 
reported only once
../../gdbtot/src/expect/exp_command.c:686: for each function it appears in.)
../../gdbtot/src/expect/exp_command.c:956: warning: assignment makes integer 
from pointer without a cast


The problem appears to be
expect/configure.in

if test -r /dev/ptmx -a "x$svr4_ptys_broken" = x -a "$cross_compiling" != "yes"
; then
  AC_MSG_RESULT(yes)
  AC_DEFINE(HAVE_PTMX)
  # aargg. Some systems need libpt.a to use /dev/ptmx
  AC_CHECK_FUNC(ptsname, , LIBS="${LIBS} -lpt")
  # I've never seen Tcl or Tk include -lpt so don't bother with explicit test
  AC_CHECK_FUNC(ptsname, , EXP_AND_TCL_LIBS="${EXP_AND_TCL_LIBS} -lpt")
  AC_CHECK_FUNC(ptsname, , EXP_AND_TK_LIBS="${EXP_AND_TK_LIBS} -lpt")
  # CYGNUS LOCAL: IA-64
  # On some systems (e.g., IA-64 Linux), we need to define _XOPEN_SOURCE
  # in order to get a declaration for ptsname.  It is safe to simply
  # define that whenever we are using ptsname.
  AC_DEFINE(_XOPEN_SOURCE)
  # END CYGNUS LOCAL
else
  AC_MSG_RESULT(no)
fi

That CYGNUS LOCAL stuff is suspect.

Defining _XOPEN_SOURCE is hazardous as that turns off
visibility of things not defined by XOPEN.
NSIG is not defined in XOPEN, I suspect.
(I've not yet checked the XPG documents to verify that NSIG
is not supposed to be visible in this case).

A workaround here is to  add
        #define NSIG 65
to expect_cf.h in the IRIX6.5 case
(in your build area)

signal.h (sys/signal.h) really does have NSIG, but
the rules call for it to be made *invisible*, I suspect.
>From the comments above this is an accidental side effect.

I have not yet figured out the right patch... Sorry.

Regards,
David B. Anderson address@hidden address@hidden http://reality.sgi.com/davea/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]