remove support for missing ANSI C header files (limits.h, stddef.h, etc).
This commit is contained in:
parent
05eb40128e
commit
7befb9966e
|
@ -15,11 +15,7 @@
|
|||
#define WITH_CYCLE_GC 1
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_LIMITS_H
|
||||
#include <limits.h>
|
||||
#else
|
||||
#error "limits.h is required by std C -- why isn't HAVE_LIMITS_H defined?"
|
||||
#endif
|
||||
|
||||
#ifndef UCHAR_MAX
|
||||
#error "Something's broken. UCHAR_MAX should be defined in limits.h."
|
||||
|
@ -40,9 +36,7 @@
|
|||
|
||||
#include <string.h>
|
||||
#include <errno.h>
|
||||
#ifdef HAVE_STDLIB_H
|
||||
#include <stdlib.h>
|
||||
#endif
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
|
|
@ -85,9 +85,7 @@ typedef PY_LONG_LONG Py_intptr_t;
|
|||
# error "Python needs a typedef for Py_uintptr_t in pyport.h."
|
||||
#endif /* HAVE_UINTPTR_T */
|
||||
|
||||
#ifdef HAVE_STDLIB_H
|
||||
#include <stdlib.h>
|
||||
#endif
|
||||
|
||||
#include <math.h> /* Moved here from the math section, before extern "C" */
|
||||
|
||||
|
|
|
@ -7,9 +7,7 @@ extern "C" {
|
|||
|
||||
/* Interface to map C struct members to Python object attributes */
|
||||
|
||||
#ifdef HAVE_STDDEF_H
|
||||
#include <stddef.h> /* For offsetof */
|
||||
#endif
|
||||
|
||||
/* The offsetof() macro calculates the offset of a structure member
|
||||
in its structure. Unfortunately this cannot be written down
|
||||
|
|
|
@ -334,6 +334,9 @@ Tools/Demos
|
|||
Build
|
||||
-----
|
||||
|
||||
- Support for missing ANSI C header files (limits.h, stddef.h, etc) was
|
||||
removed.
|
||||
|
||||
- Systems requiring the D4, D6 or D7 variants of pthreads are no longer
|
||||
supported (see PEP 11).
|
||||
|
||||
|
|
|
@ -42,15 +42,9 @@
|
|||
/* Define to 1 if you have the <stdint.h> header file. */
|
||||
#undef HAVE_STDINT_H
|
||||
|
||||
/* Define to 1 if you have the <stdlib.h> header file. */
|
||||
#define HAVE_STDLIB_H
|
||||
|
||||
/* Define to 1 if you have the <strings.h> header file. */
|
||||
#undef HAVE_STRINGS_H
|
||||
|
||||
/* Define to 1 if you have the <string.h> header file. */
|
||||
#define HAVE_STRING_H
|
||||
|
||||
/* Define to 1 if you have the <sys/stat.h> header file. */
|
||||
#undef HAVE_SYS_STAT_H
|
||||
|
||||
|
|
|
@ -53,9 +53,7 @@ corresponding Unix manual entries for more information on calls.");
|
|||
#include <sys/wait.h> /* For WNOHANG */
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SIGNAL_H
|
||||
#include <signal.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_FCNTL_H
|
||||
#include <fcntl.h>
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
#include <signal.h>
|
||||
#include <errno.h>
|
||||
|
||||
#if defined(HAVE_LOCALE_H) && defined(HAVE_SETLOCALE)
|
||||
#if defined(HAVE_SETLOCALE)
|
||||
/* GNU readline() mistakenly sets the LC_CTYPE locale.
|
||||
* This is evil. Only the user or the app's main() should do this!
|
||||
* We must save and restore the locale around the rl_initialize() call.
|
||||
|
|
|
@ -247,9 +247,7 @@ int h_errno; /* not used */
|
|||
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_STDDEF_H
|
||||
# include <stddef.h>
|
||||
#endif
|
||||
#include <stddef.h>
|
||||
|
||||
#ifndef offsetof
|
||||
# define offsetof(type, member) ((size_t)(&((type *)0)->member))
|
||||
|
|
|
@ -227,9 +227,6 @@ typedef long intptr_t;
|
|||
/* Define if you have the sigaction function. */
|
||||
#define HAVE_SIGACTION 1
|
||||
|
||||
/* Define if you have the strdup function. */
|
||||
#define HAVE_STRDUP 1
|
||||
|
||||
/* Define if you have the strerror function. */
|
||||
#define HAVE_STRERROR 1
|
||||
|
||||
|
@ -263,27 +260,9 @@ typedef long intptr_t;
|
|||
/* Define if you have the <fcntl.h> header file. */
|
||||
#define HAVE_FCNTL_H 1
|
||||
|
||||
/* Define if you have the <limits.h> header file. */
|
||||
#define HAVE_LIMITS_H 1
|
||||
|
||||
/* Define if you have the <locale.h> header file. */
|
||||
#define HAVE_LOCALE_H 1
|
||||
|
||||
/* Define if you have the <ncurses.h> header file. */
|
||||
#define HAVE_NCURSES_H 1
|
||||
|
||||
/* Define if you have the <signal.h> header file. */
|
||||
#define HAVE_SIGNAL_H 1
|
||||
|
||||
/* Define if you have the <stdarg.h> header file. */
|
||||
#define HAVE_STDARG_H 1
|
||||
|
||||
/* Define if you have the <stddef.h> header file. */
|
||||
#define HAVE_STDDEF_H 1
|
||||
|
||||
/* Define if you have the <stdlib.h> header file. */
|
||||
#define HAVE_STDLIB_H 1
|
||||
|
||||
/* Define if you have the <sys/file.h> header file. */
|
||||
#define HAVE_SYS_FILE_H 1
|
||||
|
||||
|
|
|
@ -109,29 +109,22 @@ typedef int pid_t;
|
|||
/* #undef BAD_STATIC_FORWARD */ /* if compiler botches static fwd decls */
|
||||
|
||||
#define STDC_HEADERS 1 /* VAC++ is an ANSI C Compiler */
|
||||
#define HAVE_LIMITS_H 1 /* #include <limits.h> */
|
||||
#define HAVE_STDLIB_H 1 /* #include <stdlib.h> */
|
||||
#define HAVE_HYPOT 1 /* hypot() */
|
||||
#define HAVE_PUTENV 1 /* putenv() */
|
||||
#define HAVE_STDDEF_H 1 /* #include <stddef.h> */
|
||||
/* #define VA_LIST_IS_ARRAY 1 */ /* if va_list is an array of some kind */
|
||||
|
||||
/* Variable-Arguments/Prototypes */
|
||||
#define HAVE_PROTOTYPES 1 /* VAC++ supports C Function Prototypes */
|
||||
#define HAVE_STDARG_H 1 /* #include <stdarg.h> */
|
||||
#define HAVE_STDARG_PROTOTYPES 1 /* Our <stdarg.h> has prototypes */
|
||||
|
||||
/* String/Memory/Locale Operations */
|
||||
#define HAVE_STRDUP 1 /* strdup() */
|
||||
#define HAVE_MEMMOVE 1 /* memmove() */
|
||||
#define HAVE_STRERROR 1 /* strerror() */
|
||||
#define HAVE_SETLOCALE 1 /* setlocale() */
|
||||
#define HAVE_LOCALE_H 1 /* #include <locale.h> */
|
||||
#define MALLOC_ZERO_RETURNS_NULL 1 /* Our malloc(0) returns a NULL ptr */
|
||||
|
||||
/* Signal Handling */
|
||||
#define RETSIGTYPE void /* Return type of handlers (int or void) */
|
||||
#define HAVE_SIGNAL_H 1 /* #include <signal.h> */
|
||||
/* #undef WANT_SIGFPE_HANDLER */ /* Handle SIGFPE (see Include/pyfpe.h) */
|
||||
/* #define HAVE_ALARM 1 */ /* alarm() */
|
||||
/* #define HAVE_SIGINTERRUPT 1 */ /* siginterrupt() */
|
||||
|
|
|
@ -28,7 +28,6 @@ MS_CORE_DLL.
|
|||
*/
|
||||
|
||||
#include <io.h>
|
||||
#define HAVE_LIMITS_H
|
||||
#define HAVE_SYS_UTIME_H
|
||||
#define HAVE_HYPOT
|
||||
#define HAVE_TEMPNAM
|
||||
|
@ -478,21 +477,9 @@ Py_NO_ENABLE_SHARED to find out. Also support MS_NO_COREDLL for b/w compat */
|
|||
/* Define if you have the <fcntl.h> header file. */
|
||||
#define HAVE_FCNTL_H 1
|
||||
|
||||
/* Define if you have the <signal.h> header file. */
|
||||
#define HAVE_SIGNAL_H 1
|
||||
|
||||
/* Define if you have the <stdarg.h> header file. */
|
||||
#define HAVE_STDARG_H 1
|
||||
|
||||
/* Define if you have the <stdarg.h> prototypes. */
|
||||
#define HAVE_STDARG_PROTOTYPES
|
||||
|
||||
/* Define if you have the <stddef.h> header file. */
|
||||
#define HAVE_STDDEF_H 1
|
||||
|
||||
/* Define if you have the <stdlib.h> header file. */
|
||||
#define HAVE_STDLIB_H 1
|
||||
|
||||
/* Define if you have the <sys/audioio.h> header file. */
|
||||
/* #undef HAVE_SYS_AUDIOIO_H */
|
||||
|
||||
|
|
|
@ -806,17 +806,6 @@ eval_frame(PyFrameObject *f)
|
|||
goto on_error;
|
||||
}
|
||||
}
|
||||
#if !defined(HAVE_SIGNAL_H)
|
||||
/* If we have true signals, the signal handler
|
||||
will call Py_AddPendingCall() so we don't
|
||||
have to call PyErr_CheckSignals(). On the
|
||||
Mac and DOS, alas, we have to call it. */
|
||||
if (PyErr_CheckSignals()) {
|
||||
why = WHY_EXCEPTION;
|
||||
goto on_error;
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef WITH_THREAD
|
||||
if (interpreter_lock) {
|
||||
/* Give another thread a chance */
|
||||
|
|
|
@ -13,9 +13,7 @@
|
|||
#include "eval.h"
|
||||
#include "marshal.h"
|
||||
|
||||
#ifdef HAVE_SIGNAL_H
|
||||
#include <signal.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_LANGINFO_H
|
||||
#include <locale.h>
|
||||
|
@ -1563,7 +1561,6 @@ Py_Exit(int sts)
|
|||
static void
|
||||
initsigs(void)
|
||||
{
|
||||
#ifdef HAVE_SIGNAL_H
|
||||
#ifdef SIGPIPE
|
||||
signal(SIGPIPE, SIG_IGN);
|
||||
#endif
|
||||
|
@ -1573,7 +1570,6 @@ initsigs(void)
|
|||
#ifdef SIGXFSZ
|
||||
signal(SIGXFSZ, SIG_IGN);
|
||||
#endif
|
||||
#endif /* HAVE_SIGNAL_H */
|
||||
PyOS_InitInterrupts(); /* May imply initsignal() */
|
||||
}
|
||||
|
||||
|
|
|
@ -11,13 +11,7 @@
|
|||
#include <stdio.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_STDLIB_H
|
||||
#include <stdlib.h>
|
||||
#else
|
||||
#ifdef Py_DEBUG
|
||||
extern char *getenv(const char *);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef __sgi
|
||||
#ifndef HAVE_PTHREAD_H /* XXX Need to check in configure.in */
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
/* RISCOS/pyconfig.h: Python configuration for RISC OS */
|
||||
|
||||
#ifndef Py_PYCONFIG_H
|
||||
#define Py_PYCONFIG_H
|
||||
|
||||
/* Define if on AIX 3.
|
||||
System headers sometimes define this.
|
||||
We just want to avoid a redefinition error message. */
|
||||
|
@ -577,12 +580,6 @@
|
|||
/* Define if you have the <libutil.h> header file. */
|
||||
#undef HAVE_LIBUTIL_H
|
||||
|
||||
/* Define if you have the <limits.h> header file. */
|
||||
#define HAVE_LIMITS_H 1
|
||||
|
||||
/* Define if you have the <locale.h> header file. */
|
||||
#define HAVE_LOCALE_H 1
|
||||
|
||||
/* Define if you have the <ncurses.h> header file. */
|
||||
#undef HAVE_NCURSES_H
|
||||
|
||||
|
@ -604,18 +601,6 @@
|
|||
/* Define if you have the <pty.h> header file. */
|
||||
#undef HAVE_PTY_H
|
||||
|
||||
/* Define if you have the <signal.h> header file. */
|
||||
#define HAVE_SIGNAL_H 1
|
||||
|
||||
/* Define if you have the <stdarg.h> header file. */
|
||||
#define HAVE_STDARG_H 1
|
||||
|
||||
/* Define if you have the <stddef.h> header file. */
|
||||
#define HAVE_STDDEF_H 1
|
||||
|
||||
/* Define if you have the <stdlib.h> header file. */
|
||||
#define HAVE_STDLIB_H 1
|
||||
|
||||
/* Define if you have the <sys/audioio.h> header file. */
|
||||
#undef HAVE_SYS_AUDIOIO_H
|
||||
|
||||
|
@ -706,3 +691,5 @@
|
|||
#undef DONT_HAVE_SYS_STAT_H
|
||||
|
||||
#define PLATFORM "riscos"
|
||||
|
||||
#endif /* Py_PYCONFIG_H */
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#! /bin/sh
|
||||
# From configure.in Revision: 1.450 .
|
||||
# From configure.in Revision: 1.451 .
|
||||
# Guess values for system-dependent variables and create Makefiles.
|
||||
# Generated by GNU Autoconf 2.57 for python 2.4.
|
||||
#
|
||||
|
@ -4343,15 +4343,9 @@ done
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
for ac_header in dlfcn.h fcntl.h grp.h limits.h langinfo.h \
|
||||
libintl.h locale.h ncurses.h poll.h pthread.h \
|
||||
signal.h stdarg.h stddef.h stdlib.h stropts.h termios.h thread.h \
|
||||
for ac_header in dlfcn.h fcntl.h grp.h langinfo.h \
|
||||
libintl.h ncurses.h poll.h pthread.h \
|
||||
stropts.h termios.h thread.h \
|
||||
unistd.h utime.h \
|
||||
sys/audioio.h sys/bsdtty.h sys/file.h sys/lock.h sys/mkdev.h sys/modem.h \
|
||||
sys/param.h sys/poll.h sys/select.h sys/socket.h sys/time.h sys/times.h \
|
||||
|
|
|
@ -911,9 +911,9 @@ dnl AC_MSG_RESULT($cpp_type)
|
|||
|
||||
# checks for header files
|
||||
AC_HEADER_STDC
|
||||
AC_CHECK_HEADERS(dlfcn.h fcntl.h grp.h limits.h langinfo.h \
|
||||
libintl.h locale.h ncurses.h poll.h pthread.h \
|
||||
signal.h stdarg.h stddef.h stdlib.h stropts.h termios.h thread.h \
|
||||
AC_CHECK_HEADERS(dlfcn.h fcntl.h grp.h langinfo.h \
|
||||
libintl.h ncurses.h poll.h pthread.h \
|
||||
stropts.h termios.h thread.h \
|
||||
unistd.h utime.h \
|
||||
sys/audioio.h sys/bsdtty.h sys/file.h sys/lock.h sys/mkdev.h sys/modem.h \
|
||||
sys/param.h sys/poll.h sys/select.h sys/socket.h sys/time.h sys/times.h \
|
||||
|
|
|
@ -266,15 +266,9 @@
|
|||
/* Define to 1 if you have the <libutil.h> header file. */
|
||||
#undef HAVE_LIBUTIL_H
|
||||
|
||||
/* Define to 1 if you have the <limits.h> header file. */
|
||||
#undef HAVE_LIMITS_H
|
||||
|
||||
/* Define if you have the 'link' function. */
|
||||
#undef HAVE_LINK
|
||||
|
||||
/* Define to 1 if you have the <locale.h> header file. */
|
||||
#undef HAVE_LOCALE_H
|
||||
|
||||
/* Define this if you have the type long long. */
|
||||
#undef HAVE_LONG_LONG
|
||||
|
||||
|
@ -416,9 +410,6 @@
|
|||
/* Define to 1 if you have the `siginterrupt' function. */
|
||||
#undef HAVE_SIGINTERRUPT
|
||||
|
||||
/* Define to 1 if you have the <signal.h> header file. */
|
||||
#undef HAVE_SIGNAL_H
|
||||
|
||||
/* Define to 1 if you have the `sigrelse' function. */
|
||||
#undef HAVE_SIGRELSE
|
||||
|
||||
|
@ -437,25 +428,13 @@
|
|||
/* Define if you have struct stat.st_mtim.tv_nsec */
|
||||
#undef HAVE_STAT_TV_NSEC
|
||||
|
||||
/* Define to 1 if you have the <stdarg.h> header file. */
|
||||
#undef HAVE_STDARG_H
|
||||
|
||||
/* Define if your compiler supports variable length function prototypes (e.g.
|
||||
void fprintf(FILE *, char *, ...);) *and* <stdarg.h> */
|
||||
#undef HAVE_STDARG_PROTOTYPES
|
||||
|
||||
/* Define to 1 if you have the <stddef.h> header file. */
|
||||
#undef HAVE_STDDEF_H
|
||||
|
||||
/* Define to 1 if you have the <stdint.h> header file. */
|
||||
#undef HAVE_STDINT_H
|
||||
|
||||
/* Define to 1 if you have the <stdlib.h> header file. */
|
||||
#undef HAVE_STDLIB_H
|
||||
|
||||
/* Define to 1 if you have the `strdup' function. */
|
||||
#undef HAVE_STRDUP
|
||||
|
||||
/* Define to 1 if you have the `strerror' function. */
|
||||
#undef HAVE_STRERROR
|
||||
|
||||
|
@ -465,9 +444,6 @@
|
|||
/* Define to 1 if you have the <strings.h> header file. */
|
||||
#undef HAVE_STRINGS_H
|
||||
|
||||
/* Define to 1 if you have the <string.h> header file. */
|
||||
#undef HAVE_STRING_H
|
||||
|
||||
/* Define to 1 if you have the <stropts.h> header file. */
|
||||
#undef HAVE_STROPTS_H
|
||||
|
||||
|
|
Loading…
Reference in New Issue