]> git.ipfire.org Git - thirdparty/bash.git/blame - config-bot.h
Imported from ../bash-2.05b.tar.gz.
[thirdparty/bash.git] / config-bot.h
CommitLineData
28ef6c31 1/* config-bot.h */
ccc6cda3
JA
2/* modify settings or make new ones based on what autoconf tells us. */
3
7117c2d2
JA
4/* Copyright (C) 1989-2002 Free Software Foundation, Inc.
5
6 This file is part of GNU Bash, the Bourne Again SHell.
7
8 Bash is free software; you can redistribute it and/or modify it under
9 the terms of the GNU General Public License as published by the Free
10 Software Foundation; either version 2, or (at your option) any later
11 version.
12
13 Bash is distributed in the hope that it will be useful, but WITHOUT ANY
14 WARRANTY; without even the implied warranty of MERCHANTABILITY or
15 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
16 for more details.
17
18 You should have received a copy of the GNU General Public License along
19 with Bash; see the file COPYING. If not, write to the Free Software
20 Foundation, 59 Temple Place, Suite 330, Boston, MA 02111 USA. */
21
ccc6cda3
JA
22#if !defined (HAVE_VPRINTF) && defined (HAVE_DOPRNT)
23# define USE_VFPRINTF_EMULATION
24# define HAVE_VPRINTF
25#endif
26
27/* Ultrix botches type-ahead when switching from canonical to
28 non-canonical mode, at least through version 4.3 */
29#if !defined (HAVE_TERMIOS_H) || !defined (HAVE_TCGETATTR) || defined (ultrix)
30# define TERMIOS_MISSING
31#endif
32
33/* If we have a getcwd(3), but it calls popen(), #undef HAVE_GETCWD so
34 the replacement in getcwd.c will be built. */
35#if defined (HAVE_GETCWD) && defined (GETCWD_BROKEN)
36# undef HAVE_GETCWD
37#endif
38
39#if defined (HAVE_SYS_RESOURCE_H) && defined (HAVE_GETRLIMIT)
40# define HAVE_RESOURCE
41#endif
42
43#if !defined (GETPGRP_VOID)
44# define HAVE_BSD_PGRP
45#endif
46
47#if !defined (HAVE_DEV_FD) && defined (NAMED_PIPES_MISSING)
48# undef PROCESS_SUBSTITUTION
49#endif
50
51/* If the shell is called by this name, it will become restricted. */
52#if defined (RESTRICTED_SHELL)
53# define RESTRICTED_SHELL_NAME "rbash"
54#endif
55
56/* BANG_HISTORY requires HISTORY. */
57#if defined (BANG_HISTORY) && !defined (HISTORY)
58# define HISTORY
59#endif /* BANG_HISTORY && !HISTORY */
60
61#if defined (READLINE) && !defined (HISTORY)
62# define HISTORY
63#endif
64
bb70624e
JA
65#if defined (PROGRAMMABLE_COMPLETION) && !defined (READLINE)
66# undef PROGRAMMABLE_COMPLETION
67#endif
68
ccc6cda3 69#if !defined (V9_ECHO)
bb70624e 70# undef DEFAULT_ECHO_TO_XPG
ccc6cda3
JA
71#endif
72
73#if defined (JOB_CONTROL_MISSING)
74# undef JOB_CONTROL
75#endif
76
77#if defined (__STDC__) && defined (HAVE_STDARG_H)
78# define PREFER_STDARG
79# define USE_VARARGS
80#else
81# if defined (HAVE_VARARGS_H)
82# define PREFER_VARARGS
83# define USE_VARARGS
84# endif
85#endif
d166f048
JA
86
87#if defined (STRCOLL_BROKEN)
88# undef HAVE_STRCOLL
89#endif
b72432fd 90
bb70624e
JA
91#if defined (HAVE_SYS_SOCKET_H) && defined (HAVE_GETPEERNAME) && defined (HAVE_NETINET_IN_H)
92# define HAVE_NETWORK
93#endif
94
b72432fd 95#if !defined (PROMPT_STRING_DECODE)
bb70624e 96# undef PPROMPT
b72432fd
JA
97# define PPROMPT "$ "
98#endif
7117c2d2
JA
99
100/************************************************/
101/* check multibyte capability for I18N code */
102/************************************************/
103
104/* For platforms which support the ISO C amendement 1 functionality we
105 support user defined character classes. */
106/* Solaris 2.5 has a bug: <wchar.h> must be included before <wctype.h>. */
107#if defined (HAVE_WCTYPE_H) && defined (HAVE_WCHAR_H)
108# include <wchar.h>
109# include <wctype.h>
110# if defined (HAVE_MBSRTOWCS) /* system is supposed to support XPG5 */
111# define HANDLE_MULTIBYTE 1
112# endif
113#endif
114
115/* Some systems, like BeOS, have multibyte encodings but lack mbstate_t. */
116#if HANDLE_MULTIBYTE && !defined (HAVE_MBSTATE_T)
117# define wcsrtombs(dest, src, len, ps) (wcsrtombs) (dest, src, len, 0)
118# define mbsrtowcs(dest, src, len, ps) (mbsrtowcs) (dest, src, len, 0)
119# define wcrtomb(s, wc, ps) (wcrtomb) (s, wc, 0)
120# define mbrtowc(pwc, s, n, ps) (mbrtowc) (pwc, s, n, 0)
121# define mbrlen(s, n, ps) (mbrlen) (s, n, 0)
122# define mbstate_t int
123#endif
124
125/* Make sure MB_LEN_MAX is at least 16 (some systems define
126 MB_LEN_MAX as 1) */
127#ifdef HANDLE_MULTIBYTE
128# include <limits.h>
129# if defined(MB_LEN_MAX) && (MB_LEN_MAX < 16)
130# undef MB_LEN_MAX
131# endif
132# if !defined (MB_LEN_MAX)
133# define MB_LEN_MAX 16
134# endif
135#endif
136
137/************************************************/
138/* end of multibyte capability checks for I18N */
139/************************************************/