emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master 8e5a769: Clean out some IRIX cruft


From: Paul Eggert
Subject: [Emacs-diffs] master 8e5a769: Clean out some IRIX cruft
Date: Wed, 7 Dec 2016 07:43:29 +0000 (UTC)

branch: master
commit 8e5a769965313a7a1c42b5992ed24e8b0ea71ead
Author: Paul Eggert <address@hidden>
Commit: Paul Eggert <address@hidden>

    Clean out some IRIX cruft
    
    * etc/MACHINES: Remove obsolete discussion of IRIX.
    * src/process.c (allocate_pty) [__sgi]: Remove SGI-specific code.
    (create_process) [HAVE_PTYS]: Don't worry about IRIX.
    * src/syntax.c (scan_sexps_forward): Remove obsolete comment.
    * src/unexelf.c [__sgi]: Don't include <syms.h>.
    (unexec) [__sgi]: Remove SGI-specific code.
---
 etc/MACHINES  |    9 ---------
 src/process.c |    9 ++-------
 src/syntax.c  |    2 --
 src/unexelf.c |   50 --------------------------------------------------
 4 files changed, 2 insertions(+), 68 deletions(-)

diff --git a/etc/MACHINES b/etc/MACHINES
index 15ac917..7f3c979 100644
--- a/etc/MACHINES
+++ b/etc/MACHINES
@@ -101,15 +101,6 @@ the list at the end of this file.
     ./configure CC='/usr/sfw/bin/gcc -m64'  # GCC
     ./configure CC='cc -m64'                # Solaris Studio
 
-** Irix 6.5
-
-  Emacs versions later than 24.4 will not compile on Irix by default.
-  (Note that SGI stopped supporting Irix in December 2013.)
-  Older versions of Emacs 24 (and 23?) also had problems on Irix.
-  It *may* be possible to build Emacs <= 24.4 on Irix 6.5 with an old
-  version (3.1) of gcc.  Newer versions of gcc may not work.
-  See <http://bugs.gnu.org/9684>.
-
 
 * Obsolete platforms
 
diff --git a/src/process.c b/src/process.c
index 49340b1..8ab73bd 100644
--- a/src/process.c
+++ b/src/process.c
@@ -690,11 +690,7 @@ allocate_pty (char pty_name[PTY_NAME_SIZE])
            if (faccessat (AT_FDCWD, pty_name, R_OK | W_OK, AT_EACCESS) != 0)
              {
                emacs_close (fd);
-# ifndef __sgi
                continue;
-# else
-               return -1;
-# endif /* __sgi */
              }
            setup_pty (fd);
            return fd;
@@ -1886,9 +1882,8 @@ create_process (Lisp_Object process, char **new_argv, 
Lisp_Object current_dir)
       /* Make the pty be the controlling terminal of the process.  */
 #ifdef HAVE_PTYS
       /* First, disconnect its current controlling terminal.  */
-      /* We tried doing setsid only if pty_flag, but it caused
-        process_set_signal to fail on SGI when using a pipe.  */
-      setsid ();
+      if (pty_flag)
+       setsid ();
       /* Make the pty's terminal the controlling terminal.  */
       if (pty_flag && forkin >= 0)
        {
diff --git a/src/syntax.c b/src/syntax.c
index d463f7e..338dd85 100644
--- a/src/syntax.c
+++ b/src/syntax.c
@@ -3196,8 +3196,6 @@ do { prev_from = from;                            \
          && (c1 = FETCH_CHAR (from_byte),
              syntax = SYNTAX_WITH_FLAGS (c1),
              SYNTAX_FLAGS_COMSTART_SECOND (syntax)))
-       /* Duplicate code to avoid a complex if-expression
-          which causes trouble for the SGI compiler.  */
        {
          /* Record the comment style we have entered so that only
             the comment-end sequence of the same style actually
diff --git a/src/unexelf.c b/src/unexelf.c
index 748e7a4..58c9244 100644
--- a/src/unexelf.c
+++ b/src/unexelf.c
@@ -66,9 +66,6 @@ what you give them.   Help stamp out software-hoarding!  */
 #include <sys/elf_mips.h>
 #include <sym.h>
 #endif /* _SYSTYPE_SYSV */
-#if __sgi
-#include <syms.h> /* for HDRR declaration */
-#endif /* __sgi */
 
 #ifndef MAP_ANON
 #ifdef MAP_ANONYMOUS
@@ -498,53 +495,6 @@ unexec (const char *new_name, const char *old_name)
          phdr->cbExtOffset += diff;
        }
 #endif /* __alpha__ || _SYSTYPE_SYSV */
-
-#if __sgi
-      /* Adjust  the HDRR offsets in .mdebug and copy the
-        line data if it's in its usual 'hole' in the object.
-        Makes the new file debuggable with dbx.
-        patches up two problems: the absolute file offsets
-        in the HDRR record of .mdebug (see /usr/include/syms.h), and
-        the ld bug that gets the line table in a hole in the
-        elf file rather than in the .mdebug section proper.
-        David Anderson. address@hidden  Jan 16,1994.  */
-      if (strcmp (old_section_names + new_shdr->sh_name, ".mdebug") == 0
-         && new_shdr->sh_offset - old_shdr->sh_offset != 0)
-       {
-#define MDEBUGADJUST(__ct,__fileaddr)          \
-  if (n_phdrr->__ct > 0)                       \
-    {                                          \
-      n_phdrr->__fileaddr += movement;         \
-    }
-
-         HDRR *o_phdrr = (HDRR *) ((byte *) old_base + old_shdr->sh_offset);
-         HDRR *n_phdrr = (HDRR *) ((byte *) new_base + new_shdr->sh_offset);
-         ptrdiff_t movement = new_shdr->sh_offset - old_shdr->sh_offset;
-
-         MDEBUGADJUST (idnMax, cbDnOffset);
-         MDEBUGADJUST (ipdMax, cbPdOffset);
-         MDEBUGADJUST (isymMax, cbSymOffset);
-         MDEBUGADJUST (ioptMax, cbOptOffset);
-         MDEBUGADJUST (iauxMax, cbAuxOffset);
-         MDEBUGADJUST (issMax, cbSsOffset);
-         MDEBUGADJUST (issExtMax, cbSsExtOffset);
-         MDEBUGADJUST (ifdMax, cbFdOffset);
-         MDEBUGADJUST (crfd, cbRfdOffset);
-         MDEBUGADJUST (iextMax, cbExtOffset);
-         /* The Line Section, being possible off in a hole of the object,
-            requires special handling.  */
-         if (n_phdrr->cbLine > 0)
-           {
-             n_phdrr->cbLineOffset += movement;
-
-             if (o_phdrr->cbLineOffset > (old_shdr->sh_offset
-                                          + old_shdr->sh_size))
-               /* If not covered by section, it hasn't yet been copied.  */
-               memcpy (n_phdrr->cbLineOffset + new_base,
-                       o_phdrr->cbLineOffset + old_base, n_phdrr->cbLine);
-           }
-       }
-#endif /* __sgi */
     }
 
   /* Update the symbol values of _edata and _end.  */



reply via email to

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