From c43fb4c32df6393a3e001151693b8ce28f860976 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 11 Jul 2012 13:04:19 -0400 Subject: [PATCH] Move INTERRUPT_INPUT from src/s to configure * configure.ac (INTERRUPT_INPUT): Move here from src/s. * src/s/darwin.h, src/s/gnu-linux.h, src/s/template.h: Move INTERRUPT_INPUT to configure. --- ChangeLog | 4 ++++ configure.ac | 28 ++++++++++++++++++++++++++++ src/ChangeLog | 5 +++++ src/s/darwin.h | 24 ------------------------ src/s/gnu-linux.h | 4 ---- src/s/template.h | 23 ----------------------- 6 files changed, 37 insertions(+), 51 deletions(-) diff --git a/ChangeLog b/ChangeLog index e84ed262adb..31e14a661e4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2012-07-11 Glenn Morris + + * configure.ac (INTERRUPT_INPUT): Move here from src/s. + 2012-07-11 Paul Eggert * configure.ac (tzset): Remove check that's redundant with gnulib. diff --git a/configure.ac b/configure.ac index 106b0a22481..b6029635e24 100644 --- a/configure.ac +++ b/configure.ac @@ -3172,6 +3172,34 @@ AC_DEFINE_UNQUOTED(DEFAULT_SOUND_DEVICE, "$sound_device", [Name of the default sound device.]) +dnl Emacs can read input using SIGIO and buffering characters itself, +dnl or using CBREAK mode and making C-g cause SIGINT. +dnl The choice is controlled by the variable interrupt_input. +dnl +dnl Define INTERRUPT_INPUT to make interrupt_input = 1 the default (use SIGIO) +dnl +dnl Emacs uses the presence or absence of the SIGIO and BROKEN_SIGIO macros +dnl to indicate whether or not signal-driven I/O is possible. It uses +dnl INTERRUPT_INPUT to decide whether to use it by default. +dnl +dnl SIGIO can be used only on systems that implement it (4.2 and 4.3). +dnl CBREAK mode has two disadvantages +dnl 1) At least in 4.2, it is impossible to handle the Meta key properly. +dnl I hear that in system V this problem does not exist. +dnl 2) Control-G causes output to be discarded. +dnl I do not know whether this can be fixed in system V. +dnl +dnl Another method of doing input is planned but not implemented. +dnl It would have Emacs fork off a separate process +dnl to read the input and send it to the true Emacs process +dnl through a pipe. +case $opsys in + darwin | gnu-linux | gnu-kfreebsd ) + AC_DEFINE(INTERRUPT_INPUT, 1, [Define to read input using SIGIO.]) + ;; +esac + + AH_TEMPLATE(SIGNALS_VIA_CHARACTERS, [Make process_send_signal work by "typing" a signal character on the pty.]) diff --git a/src/ChangeLog b/src/ChangeLog index ae0d7982bae..5c5f963f61b 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2012-07-11 Glenn Morris + + * s/darwin.h, s/gnu-linux.h, s/template.h: + Move INTERRUPT_INPUT to configure. + 2012-07-11 Dmitry Antipov Minor adjustments to interning code. diff --git a/src/s/darwin.h b/src/s/darwin.h index 485fadbcb1f..2a9d52a537a 100644 --- a/src/s/darwin.h +++ b/src/s/darwin.h @@ -30,30 +30,6 @@ along with GNU Emacs. If not, see . */ distinguish OS X from pure Darwin. */ #define DARWIN_OS - -/* Emacs can read input using SIGIO and buffering characters itself, - or using CBREAK mode and making C-g cause SIGINT. - The choice is controlled by the variable interrupt_input. - - Define INTERRUPT_INPUT to make interrupt_input = 1 the default (use SIGIO) - - Emacs uses the presence or absence of the SIGIO and BROKEN_SIGIO macros - to indicate whether or not signal-driven I/O is possible. It uses - INTERRUPT_INPUT to decide whether to use it by default. - - SIGIO can be used only on systems that implement it (4.2 and 4.3). - CBREAK mode has two disadvantages - 1) At least in 4.2, it is impossible to handle the Meta key properly. - I hear that in system V this problem does not exist. - 2) Control-G causes output to be discarded. - I do not know whether this can be fixed in system V. - - Another method of doing input is planned but not implemented. - It would have Emacs fork off a separate process - to read the input and send it to the true Emacs process - through a pipe. */ -#define INTERRUPT_INPUT - /* Letter to use in finding device name of first pty, if system supports pty's. 'a' means it is /dev/ptya0 */ #define FIRST_PTY_LETTER 'p' diff --git a/src/s/gnu-linux.h b/src/s/gnu-linux.h index 463ad226ec1..b4031bb1ca4 100644 --- a/src/s/gnu-linux.h +++ b/src/s/gnu-linux.h @@ -76,10 +76,6 @@ along with GNU Emacs. If not, see . */ your system and must be used only through an encapsulation (Which you should place, by convention, in sysdep.c). */ -#ifdef emacs -#define INTERRUPT_INPUT -#endif - #define POSIX /* affects getpagesize.h and systty.h */ /* This is to work around mysterious gcc failures in some system versions. diff --git a/src/s/template.h b/src/s/template.h index 83027dc591b..7f4efee0d1e 100644 --- a/src/s/template.h +++ b/src/s/template.h @@ -29,29 +29,6 @@ along with GNU Emacs. If not, see . */ /* #define BSD4_2 */ /* #define BSD_SYSTEM */ -/* Emacs can read input using SIGIO and buffering characters itself, - or using CBREAK mode and making C-g cause SIGINT. - The choice is controlled by the variable interrupt_input. - - Define INTERRUPT_INPUT to make interrupt_input = 1 the default (use SIGIO) - - Emacs uses the presence or absence of the SIGIO and BROKEN_SIGIO macros - to indicate whether or not signal-driven I/O is possible. It uses - INTERRUPT_INPUT to decide whether to use it by default. - - SIGIO can be used only on systems that implement it (4.2 and 4.3). - CBREAK mode has two disadvantages - 1) At least in 4.2, it is impossible to handle the Meta key properly. - I hear that in system V this problem does not exist. - 2) Control-G causes output to be discarded. - I do not know whether this can be fixed in system V. - - Another method of doing input is planned but not implemented. - It would have Emacs fork off a separate process - to read the input and send it to the true Emacs process - through a pipe. */ -#define INTERRUPT_INPUT - /* Letter to use in finding device name of first pty, if system supports pty's. 'a' means it is /dev/ptya0. */ #define FIRST_PTY_LETTER 'a' -- 2.39.2