This is the mail archive of the gdb-patches@sourceware.cygnus.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

[RFA/C] IRIX 6.5 with GCC build fixes


Michael,

Does the below look ok?  It is to fix the IRIX 6.5 build problems.  With
it applied, gdb starts but I'm not clear on testsuite results - dejagnu
fails when trying to fork.  A mindless play with GDB does appear to work
though.

Its for both GDB 5.0 and the trunk.

	Andrew
Mon May  8 14:49:51 2000  Andrew Cagney  <cagney@b1.cygnus.com>

	From Michael Paddon <mmpp@esec.com.au>:
	* configure.in (AC_CHECK_HEADERS): Check for <sys/user.h>.
	* configure: Re-generate.
	* proc-api.c: Only include <sys/user.h> when available.
	(ioctl_table): Check that PIOCGETPR and PIOCGETU are defined.

	* TODO, README: Update.  Mention that GDB 5 needs GCC on IRIX.

Index: README
===================================================================
RCS file: /cvs/src/src/gdb/README,v
retrieving revision 1.1.1.2.2.1
diff -p -r1.1.1.2.2.1 README
*** README	2000/04/12 16:55:15	1.1.1.2.2.1
--- README	2000/05/08 05:08:06
*************** Known bugs:
*** 531,536 ****
--- 531,539 ----
      subsystem that is on the IDO CD, otherwise you will get complaints
      that certain files such as `/usr/include/syms.h' cannot be found.
  
+   * Under Irix 6 you must build with GCC.  The vendor compiler reports
+     as errors certain assignments that GCC considers to be warnings.
+ 
    * Notes for BSD/386:
      To compile gdb-4.18 on BSD/386, you must run the configure script and
      its subscripts with bash.  Here is an easy way to do this:
*************** Known bugs:
*** 539,544 ****
--- 542,549 ----
  
      (configure will report i386-unknown-bsd).  Then, compile with the
      standard "make" command.
+   
+   * See, also the file TODO for other minor problems.
  
  GDB can produce warnings about symbols that it does not understand.  By
  default, these warnings are disabled.  You can enable them by executing
Index: TODO
===================================================================
RCS file: /cvs/src/src/gdb/TODO,v
retrieving revision 1.7.2.7
diff -p -r1.7.2.7 TODO
*** TODO	2000/04/27 00:20:19	1.7.2.7
--- TODO	2000/05/08 05:08:11
*************** release.
*** 15,30 ****
  
  --
  
! GDB doesn't build under IRIX6.4
  
! Benjamin Gamsa wrote:
  
! Has anyone successfully built the latest (from cvs) gdb on IRIX6.4 or
! later?  The first problem I hit is that proc-api.c includes
! sys/user.h, which no longer exists under IRIX6.4.  If I comment out
! that include, the next problem I hit is that PIOCGETPR and PIOCGETU
! are no longer defined in IRIX6.4 (presumably related to the
! disappearance of user.h).
  
  --
  
--- 15,26 ----
  
  --
  
! GDB requires GCC to build under IRIX
  
! IRIX, being more pedantic than GCC reports as errors certain
! assignments that GCC treats as warnings.
  
! This can be worked around by building GDB with the GCC compiler.
  
  --
  
Index: configure.in
===================================================================
RCS file: /cvs/src/src/gdb/configure.in,v
retrieving revision 1.18.2.3
diff -p -r1.18.2.3 configure.in
*** configure.in	2000/04/19 09:04:52	1.18.2.3
--- configure.in	2000/05/08 05:08:31
*************** AC_CHECK_HEADERS(ctype.h curses.h endian
*** 102,108 ****
  	string.h sys/procfs.h sys/ptrace.h sys/reg.h stdint.h \
  	term.h termio.h termios.h unistd.h wait.h sys/wait.h \
  	wchar.h wctype.h asm/debugreg.h sys/debugreg.h sys/select.h \
! 	time.h sys/ioctl.h)
  AC_HEADER_STAT
  
  AC_C_CONST
--- 102,108 ----
  	string.h sys/procfs.h sys/ptrace.h sys/reg.h stdint.h \
  	term.h termio.h termios.h unistd.h wait.h sys/wait.h \
  	wchar.h wctype.h asm/debugreg.h sys/debugreg.h sys/select.h \
! 	time.h sys/ioctl.h sys/user.h)
  AC_HEADER_STAT
  
  AC_C_CONST
Index: proc-api.c
===================================================================
RCS file: /cvs/src/src/gdb/proc-api.c,v
retrieving revision 1.1.1.1
diff -p -r1.1.1.1 proc-api.c
*** proc-api.c	2000/01/25 02:39:49	1.1.1.1
--- proc-api.c	2000/05/08 05:08:33
*************** Inc., 59 Temple Place - Suite 330, Bosto
*** 36,42 ****
--- 36,44 ----
  #include <sys/types.h>
  #include <sys/procfs.h>
  #include <sys/proc.h>	/* for struct proc */
+ #ifdef HAVE_SYS_USER_H
  #include <sys/user.h>	/* for struct user */
+ #endif
  #include <fcntl.h>	/* for O_RDWR etc. */
  #include <sys/wait.h>
  
*************** static struct trans ioctl_table[] = {
*** 110,117 ****
--- 112,123 ----
    { PIOCGETPTIMER,   "PIOCGETPTIMER",   "get process timers" },
  #endif	/* irix event counters */
    { PIOCGENTRY,    "PIOCGENTRY",   "get traced syscall entry set" },
+ #if defined (PIOCGETPR)
    { PIOCGETPR,     "PIOCGETPR",    "read struct proc" },
+ #endif
+ #if defined (PIOCGETU)
    { PIOCGETU,      "PIOCGETU",     "read user area" },
+ #endif
  #if defined (PIOCGETUTK) && (defined(KERNEL) || defined(SHOW_UTT)) /* osf */
    { PIOCGETUTK,  "PIOCGETUTK", "get the utask struct" },
  #endif

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]