summaryrefslogtreecommitdiff
path: root/src/s/gnu-linux.h
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1996-03-06 19:20:09 +0000
committerRichard M. Stallman <rms@gnu.org>1996-03-06 19:20:09 +0000
commit65953053dbffcdf4c087ad7882473d08a7c3f35d (patch)
treec520a07d07a62d59dad10a168dc6effe8f9fb52e /src/s/gnu-linux.h
parent773bb028e7355d831a58c06348ddc4cd1bfe61af (diff)
downloademacs-65953053dbffcdf4c087ad7882473d08a7c3f35d.tar.gz
(TERMINFO): Define, if HAVE_NCURSES.
(LINUX_SIGIO_DOES_WORK): Maybe define, based on Linux vers. [LINUX_SIGIO_DOES_WORK]: Don't undef SIGIO, SIGPOLL, SIGPOLL. Do define INTERRUPT_INPUT.
Diffstat (limited to 'src/s/gnu-linux.h')
-rw-r--r--src/s/gnu-linux.h42
1 files changed, 19 insertions, 23 deletions
diff --git a/src/s/gnu-linux.h b/src/s/gnu-linux.h
index efce606601d..3adf88f661b 100644
--- a/src/s/gnu-linux.h
+++ b/src/s/gnu-linux.h
@@ -1,5 +1,5 @@
/* This file is the configuration file for GNU/Linux operating systems.
- Copyright (C) 1985, 1986, 1992, 1994 Free Software Foundation, Inc.
+ Copyright (C) 1985, 1986, 1992, 1994, 1996 Free Software Foundation, Inc.
This file is part of GNU Emacs.
@@ -37,29 +37,17 @@ Boston, MA 02111-1307, USA. */
#define SYSTEM_TYPE "linux" /* All the best software is free. */
-/* 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)
-
- 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.
-*/
-
-/* There have been suggestions made to add SIGIO to Linux. If this
- is done, you may, at your discretion, uncomment the line below.
-*/
+/* Check the version number of Linux--if it is at least 1.2.0,
+ it is safe to use SIGIO. */
+#ifndef NOT_C_CODE
+#ifdef emacs
+#include <linux/version.h>
-/* #define INTERRUPT_INPUT */
+#if LINUX_VERSION_CODE > 0x10200
+#define LINUX_SIGIO_DOES_WORK
+#endif
+#endif
+#endif
/* Letter to use in finding device name of first pty,
if system supports pty's. 'p' means it is /dev/ptyp0 */
@@ -169,12 +157,16 @@ Boston, MA 02111-1307, USA. */
/* As of version 1.1.51, Linux does not actually implement SIGIO. */
/* Here we assume that signal.h is already included. */
#ifdef emacs
+#ifdef LINUX_SIGIO_DOES_WORK
+#define INTERRUPT_INPUT
+#else
#undef SIGIO
/* Some versions of Linux define SIGURG and SIGPOLL as aliases for SIGIO.
This prevents lossage in process.c. */
#undef SIGURG
#undef SIGPOLL
#endif
+#endif
/* This is needed for sysdep.c */
@@ -227,6 +219,10 @@ Boston, MA 02111-1307, USA. */
/* Paul Abrahams <abrahams@equinox.shaysnet.com> says this is needed. */
#define LIB_MOTIF -lXm -lXpm
+#ifdef HAVE_NCURSES
+#define TERMINFO
+#endif
+
#define HAVE_SYSVIPC
#ifdef __ELF__