1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318
|
# -config.sed-----------------------------------------------------------
# Configuration script for pc/config.h
# ----------------------------------------------------------------------
# Copyright (C) 2011, 2016 the Free Software Foundation, Inc.
# This file is part of GAWK, the GNU implementation of the
# AWK Programming Language.
# GAWK is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
# GAWK is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
# ----------------------------------------------------------------------
/configh\.in/a\
/* pc/config.h. Generated automatically by pc/config.sed. */
/^#undef DYNAMIC$/c\
#ifdef _WIN32\
#define DYNAMIC 1\
#endif
s/^#undef GETPGRP_VOID *$/#define GETPGRP_VOID 1/
s/^#undef GETGROUPS_T *$/#define GETGROUPS_T gid_t/
/^#undef GETPGRP_VOID$/c\
#ifdef __DJGPP__\
#define GETPGRP_VOID 1\
#endif
s/^#undef HAVE_ALARM *$/#define HAVE_ALARM 1/
s/^#undef HAVE_ATEXIT *$/#define HAVE_ATEXIT 1/
/^#undef HAVE_BTOWC *$/c\
#define HAVE_BTOWC 1
/^#undef HAVE_DECL_TZNAME *$/c\
#ifdef __MINGW32__\
#define HAVE_DECL_TZNAME 1\
#endif
s/^#undef HAVE_FCNTL_H *$/#define HAVE_FCNTL_H 1/
s/^#undef HAVE_FMOD *$/#define HAVE_FMOD 1/
/^#undef HAVE_GAI_STRERROR *$/c\
#ifdef __MINGW32__\
#define HAVE_GAI_STRERROR 1\
#endif
/^#undef HAVE_GETADDRINFO *$/c\
#ifdef __MINGW32__\
#define HAVE_GETADDRINFO 1\
#endif
/^#undef HAVE_INTMAX_T *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_INTMAX_T 1\
#endif
/^#undef HAVE_INTTYPES_H *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_INTTYPES_H 1\
#endif
/^#undef HAVE_INTTYPES_H_WITH_UINTMAX *$/c\
#ifdef __MINGW32__\
#define HAVE_INTTYPES_H_WITH_UINTMAX 1\
#endif
/^#undef HAVE_ISASCII *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_ISASCII 1\
#endif
/^#undef HAVE_ISWCTYPE *$/c\
#ifdef __MINGW32__\
#define HAVE_ISWCTYPE 1\
#endif
/^#undef HAVE_ISWLOWER *$/c\
#ifdef __MINGW32__\
#define HAVE_ISWLOWER 1\
#endif
/^#undef HAVE_ISWUPPER *$/c\
#ifdef __MINGW32__\
#define HAVE_ISWUPPER 1\
#endif
s/^#undef HAVE_LIBM *$/#define HAVE_LIBM 1/
/^#undef HAVE_LIBREADLINE *$/c\
/* #undef HAVE_LIBREADLINE */
s/^#undef HAVE_LIMITS_H *$/#define HAVE_LIMITS_H 1/
/^#undef HAVE_LOCALE_H *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_LOCALE_H 1\
#endif
/^#undef HAVE_LONG_LONG *$/c\
#ifdef __MINGW32__\
#define HAVE_LONG_LONG 1\
#endif
/^#undef HAVE_MBRLEN *$/c\
#ifdef __MINGW32__\
#define HAVE_MBRLEN 1\
#endif
/^#undef HAVE_MBRTOWC *$/c\
#ifdef __MINGW32__\
#define HAVE_MBRTOWC 1\
#endif
s/^#undef HAVE_MEMCMP *$/#define HAVE_MEMCMP 1/
s/^#undef HAVE_MEMCPY *$/#define HAVE_MEMCPY 1/
/^#undef HAVE_MEMMOVE *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_MEMMOVE 1\
#endif
/^#undef HAVE_MEMORY_H *$/c\
#ifdef __DJGPP__\
#define HAVE_MEMORY_H 1\
#endif
s/^#undef HAVE_MEMSET *$/#define HAVE_MEMSET 1/
/^#undef HAVE_MKSTEMP *$/c\
#ifdef __DJGPP__\
#define HAVE_MKSTEMP 1\
#endif
s/^#undef HAVE_MKTIME *$/#define HAVE_MKTIME 1/
/^#undef HAVE_MPFR *$/c\
/* #undef HAVE_MPFR */
/^#undef HAVE_SETENV *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_SETENV 1\
#endif
/^#undef HAVE_SETLOCALE *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_SETLOCALE 1\
#endif
/^#undef HAVE_SNPRINTF *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_SNPRINTF 1\
#endif
/^#undef HAVE_SOCKADDR_STORAGE *$/c\
#ifdef __MINGW32__\
#define HAVE_SOCKADDR_STORAGE 1\
#endif
/^#undef HAVE_SOCKETS *$/c\
#ifdef __MINGW32__\
#define HAVE_SOCKETS 1\
#endif
s/^#undef HAVE_STDARG_H *$/#define HAVE_STDARG_H 1/
/^#undef HAVE_STDBOOL_H *$/c\
#ifdef __DJGPP__\
#define HAVE_STDBOOL_H 1\
#endif
/^#undef HAVE_STDDEF_H *$/c\
#ifdef __GNUC__\
#define HAVE_STDDEF_H 1\
#endif
/^#undef HAVE_STDINT_H *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_STDINT_H 1\
#endif
/^#undef HAVE_STDLIB_H *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_STDLIB_H 1\
#endif
/^#undef HAVE_STRCASECMP *$/c\
#ifdef __DJGPP__\
#define HAVE_STRCASECMP 1\
#endif
/^#undef HAVE_STRCOLL *$/c\
#ifdef __DJGPP__\
#define HAVE_STRCOLL 1\
#endif
s/^#undef HAVE_STRCHR *$/#define HAVE_STRCHR 1/
s/^#undef HAVE_STRERROR *$/#define HAVE_STRERROR 1/
/^#undef HAVE_STRFTIME *$/c\
#ifdef __MINGW32__\
/* MinGW uses the replacement from missing_d, to support the %e specifier. */\
#define strftime rpl_strftime\
#else\
#define HAVE_STRFTIME 1\
#endif
s/^#undef HAVE_STRINGIZE *$/#define HAVE_STRINGIZE 1/
s/^#undef HAVE_STRINGS_H *$/#define HAVE_STRINGS_H 1/
s/^#undef HAVE_STRING_H *$/#define HAVE_STRING_H 1/
/^#undef HAVE_STRNCASECMP *$/c\
#define HAVE_STRNCASECMP 1\
#ifdef __EMX__\
#define strncasecmp strnicmp\
#endif
s/^#undef HAVE_STRTOD *$/#define HAVE_STRTOD 1/
/^#undef HAVE_STRTOUL *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_STRTOUL 1\
#endif
/^#undef HAVE_STRUCT_STAT_ST_BLKSIZE *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_STRUCT_STAT_ST_BLKSIZE 1\
#endif
/^#undef HAVE_SYS_IOCTL_H *$/c\
#ifdef __DJGPP__\
#define HAVE_SYS_IOCTL_H 1\
#endif
s/^#undef HAVE_SYSTEM *$/#define HAVE_SYSTEM 1/
/^#undef HAVE_SYS_PARAM_H *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_SYS_PARAM_H 1\
#endif
/^#undef HAVE_SYS_STAT_H *$/c\
#if defined(__MINGW32__) || defined(__DJGPP__)\
#define HAVE_SYS_STAT_H 1\
#endif
/^#undef HAVE_SYS_TIME_H *$/c\
#if defined(__DJGPP__) || defined(__MINGW32__)\
#define HAVE_SYS_TIME_H 1\
#endif
s/^#undef HAVE_SYS_TYPES_H *$/#define HAVE_SYS_TYPES_H 1/
/^#undef HAVE_SYS_WAIT_H *$/c\
#ifdef __DJGPP__\
#define HAVE_SYS_WAIT_H 1\
#endif
/^#undef HAVE_TMPFILE *$/c\
#ifdef __DJGPP__\
#define HAVE_TMPFILE 1\
#endif
/^#undef HAVE_TOWLOWER *$/c\
#ifdef __MINGW32__\
#define HAVE_TOWLOWER 1\
#endif
/^#undef HAVE_TOWUPPER *$/c\
#ifdef __MINGW32__\
#define HAVE_TOWUPPER 1\
#endif
s/^#undef HAVE_TZNAME *$/#define HAVE_TZNAME 1/
s/^#undef HAVE_TZSET *$/#define HAVE_TZSET 1/
/^#undef HAVE_UINTMAX_T *$/c\
#if defined(__DJGPP__) || defined(__MINGW32__)\
#define HAVE_UINTMAX_T 1\
#endif
/^#undef HAVE_UNISTD_H *$/c\
#if defined(__DJGPP__) || defined(__MINGW32__)\
#define HAVE_UNISTD_H 1\
#endif
s/^#undef HAVE_UNSIGNED_LONG_LONG *$/#define HAVE_UNSIGNED_LONG_LONG 1/
/^#undef HAVE_USLEEP *$/c\
#if defined(__DJGPP__) || defined(__MINGW32__)\
#define HAVE_USLEEP 1\
#endif
s/^#undef HAVE_VPRINTF *$/#define HAVE_VPRINTF 1/
/^#undef HAVE_WCHAR_H *$/c\
#ifdef __MINGW32__\
#define HAVE_WCHAR_H 1\
#endif
/^#undef HAVE_WCRTOMB *$/c\
#ifdef __MINGW32__\
#define HAVE_WCRTOMB 1\
#endif
/^#undef HAVE_WCSCOLL *$/c\
#ifdef __MINGW32__\
#define HAVE_WCSCOLL 1\
#endif
/^#undef HAVE_WCTYPE *$/c\
#ifdef __MINGW32__\
#define HAVE_WCTYPE 1\
#endif
/^#undef HAVE_WCTYPE_H *$/c\
#ifdef __MINGW32__\
#define HAVE_WCTYPE_H 1\
#endif
/^#undef HAVE_WCTYPE_T *$/c\
#ifdef __MINGW32__\
#define HAVE_WCTYPE_T 1\
#endif
/^#undef HAVE_WINT_T *$/c\
#ifdef __MINGW32__\
#define HAVE_WINT_T 1\
#endif
/^#undef HAVE__BOOL *$/c\
#ifdef __DJGPP__\
#define HAVE__BOOL 1\
#endif
/^#undef PRINTF_HAS_F_FORMAT *$/c\
#ifdef __DJGPP__\
#define PRINTF_HAS_F_FORMAT 1\
#endif
s/^#undef PROTOTYPES *$/#define PROTOTYPES 1/
s/^#undef RETSIGTYPE *$/#define RETSIGTYPE void/
/^#.*RETSIGTYPE /a\
\
#if defined(__DJGPP__) || defined(__MINGW32__)\
#include <limits.h>\
#endif
s/^#undef SIZEOF_UNSIGNED_INT *$/#define SIZEOF_UNSIGNED_INT 4/
s/^#undef SIZEOF_UNSIGNED_LONG *$/#define SIZEOF_UNSIGNED_LONG 4/
s/^#undef STDC_HEADERS *$/#define STDC_HEADERS 1/
s/^#undef TIME_WITH_SYS_TIME *$/#define TIME_WITH_SYS_TIME 1/
/^#undef inline *$/c\
#ifdef __GNUC__\
#define inline __inline__\
#endif
s|^#undef PACKAGE_URL *$|#define PACKAGE_URL "http://www.gnu.org/software/gawk/"|
$a\
#ifdef __DJGPP__\
/* gcc no longer includes this by default */\
# include <sys/version.h>\
\
/* Library search path */\
# if (__DJGPP__ > 2 || __DJGPP_MINOR__ >= 3)\
# define DEFPATH ".;/dev/env/DJDIR/share/awk"\
# else\
# define DEFPATH ".;c:/lib/awk;c:/gnu/lib/awk"\
# endif\
#endif\
\
#ifndef __DJGPP__\
#define HAVE_POPEN_H 1\
#endif\
\
#if defined(__EMX__)\
#define strcasecmp stricmp\
#define strncasecmp strnicmp\
#endif
|