From: Alexandre Oliva <aoliva@redhat.com>
To: gdb-patches@sources.redhat.com
Subject: changes for expect to build on IRIX 6
Date: Wed, 15 Jan 2003 11:15:00 -0000 [thread overview]
Message-ID: <orptqy7jgh.fsf@free.redhat.lsd.ic.unicamp.br> (raw)
[-- Attachment #1: Type: text/plain, Size: 167 bytes --]
I needed these changes in order for the copy of expect in srcware to
build on IRIX 6. Some of the changes were needed by GCC, some by the
native cc. Ok to install?
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: expect-irix.patch --]
[-- Type: text/x-patch, Size: 2937 bytes --]
Index: expect/ChangeLog
from Alexandre Oliva <aoliva@redhat.com>
* exp_trap.c (NSIG): Define to SIGRTMAX if needed and possible.
* exp_command.c (NSIG): Likewise.
(Exp_SpawnCmd): Don't define rfd and wfd as pointers, but
rather as longs, and only if TCL_MAJOR_VERSION < 8.
* pty_termios.c (_getpty): Declare if HAVE__GETPTY.
Index: expect/exp_command.c
===================================================================
RCS file: /cvs/src/src/expect/exp_command.c,v
retrieving revision 1.5
diff -u -p -r1.5 exp_command.c
--- expect/exp_command.c 20 Nov 2002 00:28:58 -0000 1.5
+++ expect/exp_command.c 15 Jan 2003 11:11:47 -0000
@@ -56,6 +56,15 @@ would appreciate credit if this program
#endif
#endif
+/* IRIX 6 defines NSIG only if _SGI_SOURCE (or something alike) is
+ defined. But it defines SIGRTMAX to the same value, so use
+ that... */
+#ifndef NSIG
+#ifdef SIGRTMAX
+#define NSIG SIGRTMAX
+#endif
+#endif
+
#ifdef HAVE_PTYTRAP
#include <sys/ptyio.h>
#endif
@@ -853,12 +862,15 @@ when trapping, see below in child half o
int mode;
#if TCL_MAJOR_VERSION < 8
Tcl_File tclReadFile, tclWriteFile;
-#endif /* TCL_MAJOR_VERSION < 8 */
/* CYGNUS LOCAL 64bit/law */
- /* These must be both wide enough and aligned enough for
- the TCL code to store a pointer into them! */
- void *rfd, *wfd;
+ /* rfd and wfd must be both wide enough and aligned
+ enough for the <8 TCL code to store a pointer into
+ them! The assumption is that long int is as wide
+ as a pointer. */
+ long
/* END CYGNUS LOCAL */
+#endif /* TCL_MAJOR_VERSION < 8 */
+ int rfd, wfd;
if (echo) exp_log(0,"%s [open ...]\r\n",argv0);
Index: expect/exp_trap.c
===================================================================
RCS file: /cvs/src/src/expect/exp_trap.c,v
retrieving revision 1.1.1.1
diff -u -p -r1.1.1.1 exp_trap.c
--- expect/exp_trap.c 9 Nov 1999 01:28:43 -0000 1.1.1.1
+++ expect/exp_trap.c 15 Jan 2003 11:11:47 -0000
@@ -25,6 +25,15 @@ would appreciate credit if this program
#endif
#endif
+/* IRIX 6 defines NSIG only if _SGI_SOURCE (or something alike) is
+ defined. But it defines SIGRTMAX to the same value, so use
+ that... */
+#ifndef NSIG
+#ifdef SIGRTMAX
+#define NSIG SIGRTMAX
+#endif
+#endif
+
#if defined(SIGCLD) && !defined(SIGCHLD)
#define SIGCHLD SIGCLD
#endif
Index: expect/pty_termios.c
===================================================================
RCS file: /cvs/src/src/expect/pty_termios.c,v
retrieving revision 1.3
diff -u -p -r1.3 pty_termios.c
--- expect/pty_termios.c 11 Sep 2001 19:24:03 -0000 1.3
+++ expect/pty_termios.c 15 Jan 2003 11:11:48 -0000
@@ -113,6 +113,10 @@ static char *tty_num; /* ptr to char [0
which number it is */
#endif
+#ifdef HAVE__GETPTY
+extern char *_getpty();
+#endif
+
#if defined(_SEQUENT_) && !defined(HAVE_PTMX)
/* old-style SEQUENT, new-style uses ptmx */
static char *master_name, *slave_name;
[-- Attachment #3: Type: text/plain, Size: 289 bytes --]
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{redhat.com, gcc.gnu.org}
CS PhD student at IC-Unicamp oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist Professional serial bug killer
next reply other threads:[~2003-01-15 11:15 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-01-15 11:15 Alexandre Oliva [this message]
2003-01-15 12:42 ` Ben Elliston
2003-01-15 16:02 ` Andrew Cagney
2003-01-15 20:25 ` Ben Elliston
2003-01-17 5:31 ` Alexandre Oliva
2003-01-17 16:07 ` Andrew Cagney
2003-01-19 15:15 ` Alexandre Oliva
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=orptqy7jgh.fsf@free.redhat.lsd.ic.unicamp.br \
--to=aoliva@redhat.com \
--cc=gdb-patches@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox