1 /* System description header file for Cygwin.
3 Copyright (C) 1985-1986, 1992, 1999, 2002-2012 Free Software Foundation, Inc.
5 This file is part of GNU Emacs.
7 GNU Emacs is free software: you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation, either version 3 of the License, or
10 (at your option) any later version.
12 GNU Emacs is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
20 /* SYSTEM_TYPE should indicate the kind of system you are using.
21 It sets the Lisp variable system-type. */
22 #define SYSTEM_TYPE "cygwin"
24 /* Emacs can read input using SIGIO and buffering characters itself,
25 or using CBREAK mode and making C-g cause SIGINT.
26 The choice is controlled by the variable interrupt_input.
28 Define INTERRUPT_INPUT to make interrupt_input = 1 the default (use SIGIO)
30 Emacs uses the presence or absence of the SIGIO and BROKEN_SIGIO macros
31 to indicate whether or not signal-driven I/O is possible. It uses
32 INTERRUPT_INPUT to decide whether to use it by default.
34 SIGIO can be used only on systems that implement it (4.2 and 4.3).
35 CBREAK mode has two disadvantages
36 1) At least in 4.2, it is impossible to handle the Meta key properly.
37 I hear that in system V this problem does not exist.
38 2) Control-G causes output to be discarded.
39 I do not know whether this can be fixed in system V.
41 Another method of doing input is planned but not implemented.
42 It would have Emacs fork off a separate process
43 to read the input and send it to the true Emacs process
45 #undef INTERRUPT_INPUT
47 /* Define HAVE_PTYS if the system supports pty devices. */
49 #define PTY_ITERATION int i; for (i = 0; i < 1; i++) /* ick */
50 #define PTY_NAME_SPRINTF /* none */
51 #define PTY_TTY_NAME_SPRINTF /* none */
57 mask = sigblock (sigmask (SIGCHLD)); \
58 if (-1 == openpty (&fd, &dummy, pty_name, 0, 0)) \
62 emacs_close (dummy); \
66 /* Define CLASH_DETECTION if you want lock files to be written
67 so that Emacs can tell instantly when you try to modify
68 a file that someone else has modified in his Emacs. */
69 #define CLASH_DETECTION
71 /* If the system's imake configuration file defines `NeedWidePrototypes'
72 as `NO', we must define NARROWPROTO manually. Such a define is
73 generated in the Makefile generated by `xmkmf'. If we don't
74 define NARROWPROTO, we will see the wrong function prototypes
75 for X functions taking float or double parameters. */
78 /* Used in various places to enable cygwin-specific code changes. */
81 #define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_p - (FILE)->_bf._base)
85 /* Emacs supplies its own malloc, but glib (part of Gtk+) calls
86 memalign and on Cygwin, that becomes the Cygwin-supplied memalign.
87 As malloc is not the Cygwin malloc, the Cygwin memalign always
88 returns ENOSYS. A workaround is to set G_SLICE=always-malloc. */
89 #define G_SLICE_ALWAYS_MALLOC
91 /* Send signals to subprocesses by "typing" special chars at them. */
92 #define SIGNALS_VIA_CHARACTERS