Mercurial > emacs
diff src/sysdep.c @ 96303:ddedcecb18ef
* unexnext.c:
* m/ews4800.h:
* m/hp9000s300.h:
* m/ibm370aix.h:
* m/mips-siemens.h:
* m/ncr386.h:
* m/next.h:
* m/pmax.h:
* m/powerpcle.h:
* m/tandem-s2.h:
* s/386bsd.h:
* s/bsd386.h:
* s/bsd4-1.h:
* s/bsd4-2.h:
* s/bsdos2-1.h:
* s/bsdos2.h:
* s/bsdos3.h:
* s/bsdos4.h:
* s/nextstep.h:
* s/ultrix4-3.h:
* s/usg5-0.h:
* s/usg5-2-2.h:
* s/usg5-2.h:
* s/usg5-4-3.h:
* s/ux4800.h:
* s/uxpds.h:
* s/uxpv.h: Remove support for obsolete systems.
* s/hpux.h, s/hpux10.h, s/hpux8.h, s/hpux9.h, s/hpux9shr.h:
Remove, insert contents in s/hpux-10.20.h
* s/aix3-1.h, s/aix3-2-5.h, s/aix3-2.h, s/aix4-1.h, s/aix4.h:
Remove, insert contents in s/aix-4.2.h
* s/usg5-3.h: Remove, insert contents in s/usg5-4.h.
* s/bsd4-3.h: Rename to ..
* s/bsd-common.h: ... this.
* src/data.c:
* src/doc.c:
* src/ecrt0.c:
* src/emacs.c:
* src/fileio.c:
* src/floatfns.c:
* src/keyboard.c:
* src/mem-limits.h:
* src/print.c:
* src/process.c:
* src/sysdep.c:
* src/syssignal.h:
* src/systty.h:
* src/syswait.h:
* src/term.c:
* src/unexec.c:
* src/unexelf.c:
* src/unexhp9k800.c:
* src/m/hp800.h:
* src/m/ibmrs6000.h:
* src/m/mips.h:
* src/m/vax.h:
* src/s/darwin.h:
* src/s/freebsd.h:
* src/s/gnu.h:
* src/s/ms-w32.h:
* src/s/msdos.h:
* src/s/netbsd.h:
* src/s/template.h: Remove references to obsolete variables.
* Makefile.in: Add dependencies for all unexec files.
(admindir): Remove unused variable.
(UNEXEC_SRC): Remove references.
* config.nt: Remove reference to UNEXEC_SRC.
* lwlib.c: Remove references to obsolete variables.
* fakemail.c: Remove references to obsolete variables.
* os.texi: Remove references to obsolete systems.
* configure.in:
* configure: Remove references to obsolete systems.
| author | Dan Nicolaescu <dann@ics.uci.edu> |
|---|---|
| date | Thu, 26 Jun 2008 04:24:54 +0000 |
| parents | eb403674cfbf |
| children | 7d463685c286 |
line wrap: on
line diff
--- a/src/sysdep.c Thu Jun 26 04:17:19 2008 +0000 +++ b/src/sysdep.c Thu Jun 26 04:24:54 2008 +0000 @@ -206,10 +206,6 @@ #define LPASS8 0 #endif -#ifdef BSD4_1 -#define LNOFLSH 0100000 -#endif - static int baud_convert[] = #ifdef BAUD_CONVERT BAUD_CONVERT; @@ -235,11 +231,6 @@ void croak P_ ((char *)) NO_RETURN; -#ifdef AIXHFT -void hft_init P_ ((struct tty_display_info *)); -void hft_reset P_ ((struct tty_display_info *)); -#endif - /* Temporary used by `sigblock' when defined in terms of signprocmask. */ SIGMASKTYPE sigprocmask_set; @@ -483,7 +474,7 @@ status = SYS$FORCEX (&pid, 0, 0); break; #else /* not VMS */ -#if defined (BSD_SYSTEM) || (defined (HPUX) && !defined (HPUX_5)) +#if defined (BSD_SYSTEM) || defined (HPUX) /* Note that kill returns -1 even if the process is just a zombie now. But inevitably a SIGCHLD interrupt should be generated and child_sig will do wait3 and make the process go away. */ @@ -542,16 +533,9 @@ #if __DJGPP__ > 1 break; #else /* not __DJGPP__ > 1 */ -#ifndef BSD4_1 if (kill (pid, 0) < 0) break; wait (0); -#else /* BSD4_1 */ - int status; - status = wait (0); - if (status == pid || status == -1) - break; -#endif /* BSD4_1 */ #endif /* not __DJGPP__ > 1*/ #endif /* not subprocesses */ } @@ -695,10 +679,6 @@ EMACS_SET_TTY (out, &s, 0); -#ifdef BSD4_1 - if (interrupt_input) - reset_sigio (0); -#endif /* BSD4_1 */ #endif /* not DOS_NT */ } #endif /* not VMS */ @@ -1267,12 +1247,6 @@ -#ifdef BSD4_1 -/* BSD 4.1 needs to keep track of the lmode bits in order to start - sigio. */ -int lmode; -#endif - #ifdef F_SETOWN int old_fcntl_owner[MAXDESC]; #endif /* F_SETOWN */ @@ -1281,15 +1255,11 @@ but if so, this does no harm, and using the same name avoids wasting the other one's space. */ -#ifdef nec_ews_svr4 -extern char *_sobuf ; -#else #if defined (USG) || defined (DGUX) unsigned char _sobuf[BUFSIZ+8]; #else char _sobuf[BUFSIZ]; #endif -#endif #ifdef HAVE_LTCHARS static struct ltchars new_ltchars = {-1,-1,-1,-1,-1,-1}; @@ -1495,11 +1465,6 @@ } #endif /* mips or HAVE_TCATTR */ -#ifdef SET_LINE_DISCIPLINE - /* Need to explicitly request TERMIODISC line discipline or - Ultrix's termios does not work correctly. */ - tty.main.c_line = SET_LINE_DISCIPLINE; -#endif #ifdef AIX #ifndef IBMR2AIX /* AIX enhanced edit loses NULs, so disable it. */ @@ -1566,16 +1531,7 @@ } tty.lmode = LDECCTQ | LLITOUT | LPASS8 | LNOFLSH | tty_out->old_tty.lmode; -#ifdef ultrix - /* Under Ultrix 4.2a, leaving this out doesn't seem to hurt - anything, and leaving it in breaks the meta key. Go figure. */ - tty.lmode &= ~LLITOUT; -#endif -#ifdef BSD4_1 - lmode = tty.lmode; -#endif - #endif /* HAVE_TCHARS */ #endif /* not HAVE_TERMIO */ @@ -1600,26 +1556,12 @@ if (!tty_out->flow_control) ioctl (fileno (tty_out->input), TIOCSTART, 0); #endif -#if defined (HAVE_TERMIOS) || defined (HPUX9) +#if defined (HAVE_TERMIOS) || defined (HPUX) #ifdef TCOON if (!tty_out->flow_control) tcflow (fileno (tty_out->input), TCOON); #endif #endif -#ifdef AIXHFT - hft_init (tty_out); -#ifdef IBMR2AIX - { - /* IBM's HFT device usually thinks a ^J should be LF/CR. We need it - to be only LF. This is the way that is done. */ - struct termio tty; - - if (ioctl (1, HFTGETID, &tty) != -1) - write (1, "\033[20l", 5); - } -#endif -#endif /* AIXHFT */ - #ifdef VMS /* Appears to do nothing when in PASTHRU mode. SYS$QIOW (0, fileno (tty_out->input), IO$_SETMODE|IO$M_OUTBAND, 0, 0, 0, @@ -1649,11 +1591,6 @@ #endif /* F_GETOWN */ #endif /* F_SETFL */ -#ifdef BSD4_1 - if (interrupt_input) - init_sigio (fileno (tty_out->input)); -#endif - #ifdef VMS /* VMS sometimes has this symbol but lacks setvbuf. */ #undef _IOFBF #endif @@ -1868,26 +1805,13 @@ cmgoto (tty_out, FrameRows (tty_out) - 1, 0); fflush (tty_out->output); -#if defined (IBMR2AIX) && defined (AIXHFT) - { - /* HFT devices normally use ^J as a LF/CR. We forced it to - do the LF only. Now, we need to reset it. */ - struct termio tty; - - if (ioctl (1, HFTGETID, &tty) != -1) - write (1, "\033[20h", 5); - } -#endif - if (tty_out->terminal->reset_terminal_modes_hook) tty_out->terminal->reset_terminal_modes_hook (tty_out->terminal); #ifdef BSD_SYSTEM -#ifndef BSD4_1 /* Avoid possible loss of output when changing terminal modes. */ fsync (fileno (tty_out->output)); #endif -#endif #ifdef F_SETFL #ifdef F_SETOWN /* F_SETFL does not imply existence of F_SETOWN */ @@ -1903,10 +1827,6 @@ fcntl (fileno (tty_out->input), F_GETFL, 0) & ~O_NDELAY); #endif #endif /* F_SETFL */ -#ifdef BSD4_1 - if (interrupt_input) - reset_sigio (fileno (tty_out->input)); -#endif /* BSD4_1 */ if (tty_out->old_tty) while (EMACS_SET_TTY (fileno (tty_out->input), @@ -1917,17 +1837,6 @@ dos_ttcooked (); #endif -#ifdef SET_LINE_DISCIPLINE - /* Ultrix's termios *ignores* any line discipline except TERMIODISC. - A different old line discipline is therefore not restored, yet. - Restore the old line discipline by hand. */ - ioctl (0, TIOCSETD, &tty_out->old_tty.main.c_line); -#endif - -#ifdef AIXHFT - hft_reset (); -#endif - #ifdef BSD_PGRPS widen_foreground_group (fileno (tty_out->input)); #endif @@ -2318,20 +2227,14 @@ /* init_system_name sets up the string for the Lisp function system-name to return. */ -#ifdef BSD4_1 -#include <whoami.h> -#endif - extern Lisp_Object Vsystem_name; -#ifndef BSD4_1 #ifndef VMS #ifdef HAVE_SOCKETS #include <sys/socket.h> #include <netdb.h> #endif /* HAVE_SOCKETS */ #endif /* not VMS */ -#endif /* not BSD4_1 */ #ifdef TRY_AGAIN #ifndef HAVE_H_ERRNO @@ -2342,9 +2245,6 @@ void init_system_name () { -#ifdef BSD4_1 - Vsystem_name = build_string (sysname); -#else #ifdef VMS char *sp, *end; if ((sp = egetenv ("SYS$NODE")) == 0) @@ -2525,7 +2425,6 @@ Vsystem_name = build_string (hostname); #endif /* HAVE_GETHOSTNAME */ #endif /* VMS */ -#endif /* BSD4_1 */ { unsigned char *p; for (p = SDATA (Vsystem_name); *p; p++) @@ -2567,11 +2466,7 @@ select_alarm () { select_alarmed = 1; -#ifdef BSD4_1 - sigrelse (SIGALRM); -#else /* not BSD4_1 */ signal (SIGALRM, SIG_IGN); -#endif /* not BSD4_1 */ SIGNAL_THREAD_CHECK (SIGALRM); if (read_alarm_should_throw) longjmp (read_alarm_throw, 1); @@ -2782,93 +2677,6 @@ #endif /* not VMS */ #endif /* not MSDOS */ -#ifdef BSD4_1 -void -init_sigio (fd) - int fd; -{ - if (noninteractive) - return; - lmode = LINTRUP | lmode; - ioctl (fd, TIOCLSET, &lmode); -} - -void -reset_sigio (fd) - int fd; -{ - if (noninteractive) - return; - lmode = ~LINTRUP & lmode; - ioctl (fd, TIOCLSET, &lmode); -} - -void -request_sigio () -{ - if (noninteractive) - return; - sigrelse (SIGTINT); - - interrupts_deferred = 0; -} - -void -unrequest_sigio () -{ - if (noninteractive) - return; - sighold (SIGTINT); - - interrupts_deferred = 1; -} - -/* still inside #ifdef BSD4_1 */ -#ifdef subprocesses - -int sigheld; /* Mask of held signals */ - -void -sigholdx (signum) - int signum; -{ - sigheld |= sigbit (signum); - sighold (signum); -} - -void -sigisheld (signum) - int signum; -{ - sigheld |= sigbit (signum); -} - -void -sigunhold (signum) - int signum; -{ - sigheld &= ~sigbit (signum); - sigrelse (signum); -} - -void -sigfree () /* Free all held signals */ -{ - int i; - for (i = 0; i < NSIG; i++) - if (sigheld & sigbit (i)) - sigrelse (i); - sigheld = 0; -} - -int -sigbit (i) -{ - return 1 << (i - 1); -} -#endif /* subprocesses */ -#endif /* BSD4_1 */ - /* POSIX signals support - DJB */ /* Anyone with POSIX signals should have ANSI C declarations */ @@ -3327,11 +3135,6 @@ { register int rtnval; -#ifdef BSD4_1 - if (oflag & O_CREAT) - return creat (path, mode); -#endif - while ((rtnval = open (path, oflag, mode)) == -1 && (errno == EINTR)) QUIT; @@ -5189,100 +4992,6 @@ } #endif /* VMS */ -#ifdef AIXHFT - -/* Called from init_sys_modes. */ -void -hft_init (struct tty_display_info *tty_out) -{ - int junk; - - /* If we're not on an HFT we shouldn't do any of this. We determine - if we are on an HFT by trying to get an HFT error code. If this - call fails, we're not on an HFT. */ -#ifdef IBMR2AIX - if (ioctl (0, HFQERROR, &junk) < 0) - return; -#else /* not IBMR2AIX */ - if (ioctl (0, HFQEIO, 0) < 0) - return; -#endif /* not IBMR2AIX */ - - /* On AIX the default hft keyboard mapping uses backspace rather than delete - as the rubout key's ASCII code. Here this is changed. The bug is that - there's no way to determine the old mapping, so in reset_sys_modes - we need to assume that the normal map had been present. Of course, this - code also doesn't help if on a terminal emulator which doesn't understand - HFT VTD's. */ - { - struct hfbuf buf; - struct hfkeymap keymap; - - buf.hf_bufp = (char *)&keymap; - buf.hf_buflen = sizeof (keymap); - keymap.hf_nkeys = 2; - keymap.hfkey[0].hf_kpos = 15; - keymap.hfkey[0].hf_kstate = HFMAPCHAR | HFSHFNONE; -#ifdef IBMR2AIX - keymap.hfkey[0].hf_keyidh = '<'; -#else /* not IBMR2AIX */ - keymap.hfkey[0].hf_page = '<'; -#endif /* not IBMR2AIX */ - keymap.hfkey[0].hf_char = 127; - keymap.hfkey[1].hf_kpos = 15; - keymap.hfkey[1].hf_kstate = HFMAPCHAR | HFSHFSHFT; -#ifdef IBMR2AIX - keymap.hfkey[1].hf_keyidh = '<'; -#else /* not IBMR2AIX */ - keymap.hfkey[1].hf_page = '<'; -#endif /* not IBMR2AIX */ - keymap.hfkey[1].hf_char = 127; - hftctl (0, HFSKBD, &buf); - } -} - -/* Reset the rubout key to backspace. */ - -void -hft_reset (struct tty_display_info *tty_out) -{ - struct hfbuf buf; - struct hfkeymap keymap; - int junk; - -#ifdef IBMR2AIX - if (ioctl (0, HFQERROR, &junk) < 0) - return; -#else /* not IBMR2AIX */ - if (ioctl (0, HFQEIO, 0) < 0) - return; -#endif /* not IBMR2AIX */ - - buf.hf_bufp = (char *)&keymap; - buf.hf_buflen = sizeof (keymap); - keymap.hf_nkeys = 2; - keymap.hfkey[0].hf_kpos = 15; - keymap.hfkey[0].hf_kstate = HFMAPCHAR | HFSHFNONE; -#ifdef IBMR2AIX - keymap.hfkey[0].hf_keyidh = '<'; -#else /* not IBMR2AIX */ - keymap.hfkey[0].hf_page = '<'; -#endif /* not IBMR2AIX */ - keymap.hfkey[0].hf_char = 8; - keymap.hfkey[1].hf_kpos = 15; - keymap.hfkey[1].hf_kstate = HFMAPCHAR | HFSHFSHFT; -#ifdef IBMR2AIX - keymap.hfkey[1].hf_keyidh = '<'; -#else /* not IBMR2AIX */ - keymap.hfkey[1].hf_page = '<'; -#endif /* not IBMR2AIX */ - keymap.hfkey[1].hf_char = 8; - hftctl (0, HFSKBD, &buf); -} - -#endif /* AIXHFT */ - - #ifndef BSTRING #ifndef bzero
