* Makefile.in (init.c): Generate with prototypes.
[deliverable/binutils-gdb.git] / gdb / config / rs6000 / xm-rs6000.h
CommitLineData
5076de82
FF
1/* Parameters for hosting on an RS6000, for GDB, the GNU debugger.
2 Copyright 1986, 1987, 1989, 1991, 1992, 1993 Free Software Foundation, Inc.
3 Contributed by IBM Corporation.
4
5This file is part of GDB.
6
7This program is free software; you can redistribute it and/or modify
8it under the terms of the GNU General Public License as published by
9the Free Software Foundation; either version 2 of the License, or
10(at your option) any later version.
11
12This program is distributed in the hope that it will be useful,
13but WITHOUT ANY WARRANTY; without even the implied warranty of
14MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15GNU General Public License for more details.
16
17You should have received a copy of the GNU General Public License
18along with this program; if not, write to the Free Software
6c9638b4 19Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
5076de82
FF
20
21/* The following text is taken from config/rs6000.mh:
22 * # The IBM version of /usr/include/rpc/rpc.h has a bug -- it says
23 * # `extern fd_set svc_fdset;' without ever defining the type fd_set.
24 * # Unfortunately this occurs in the vx-share code, which is not configured
25 * # like the rest of GDB (e.g. it doesn't include "defs.h").
26 * # We circumvent this bug by #define-ing fd_set here, but undefining it in
27 * # the xm-rs6000.h file before ordinary modules try to use it. FIXME, IBM!
28 * MH_CFLAGS='-Dfd_set=int'
29 * So, here we do the undefine...which has to occur before we include
30 * <sys/select.h> below.
31 */
32#undef fd_set
33
34#include <sys/select.h>
35
36/* Big end is at the low address */
37
38#define HOST_BYTE_ORDER BIG_ENDIAN
39
c2e247c4
JK
40/* At least as of AIX 3.2, we have termios. */
41#define HAVE_TERMIOS 1
42/* #define HAVE_TERMIO 1 */
43
5076de82
FF
44#define USG 1
45#define HAVE_SIGSETMASK 1
46
407f52c1
JL
47#define FIVE_ARG_PTRACE
48
5076de82
FF
49/* This system requires that we open a terminal with O_NOCTTY for it to
50 not become our controlling terminal. */
51
52#define USE_O_NOCTTY
53
5076de82
FF
54/* Brain death inherited from PC's pervades. */
55#undef NULL
56#define NULL 0
57
58/* The IBM compiler requires this in order to properly compile alloca(). */
59#pragma alloca
60
61/* There is no vfork. */
62
63#define vfork fork
64
65/* Setpgrp() takes arguments, unlike ordinary Sys V's. */
66
67#define SETPGRP_ARGS 1
68
5076de82
FF
69/* AIX doesn't have strdup, so we need to declare it for libiberty */
70extern char *strdup PARAMS ((char *));
71
72/* Signal handler for SIGWINCH `window size changed'. */
73
74#define SIGWINCH_HANDLER aix_resizewindow
81a80f32 75extern void aix_resizewindow PARAMS ((void));
5076de82 76
359a097f
JK
77/* This doesn't seem to be declared in any header file I can find. */
78char *termdef PARAMS ((int, int));
79
5076de82
FF
80/* `lines_per_page' and `chars_per_line' are local to utils.c. Rectify this. */
81
82#define SIGWINCH_HANDLER_BODY \
83 \
84/* Respond to SIGWINCH `window size changed' signal, and reset GDB's \
85 window settings approproatelt. */ \
86 \
87void \
88aix_resizewindow () \
89{ \
90 int fd = fileno (stdout); \
91 if (isatty (fd)) { \
92 int val; \
93 \
94 val = atoi (termdef (fd, 'l')); \
95 if (val > 0) \
96 lines_per_page = val; \
97 val = atoi (termdef (fd, 'c')); \
98 if (val > 0) \
99 chars_per_line = val; \
100 } \
101}
8bab3808
C
102
103/* setpgrp() messes up controling terminal. The other version of it
104 requires libbsd.a. */
105#define setpgrp(XX,YY) setpgid (XX, YY)
106
This page took 0.172856 seconds and 4 git commands to generate.