mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-04-30 03:40:34 +02:00
[slog] Assume STDC_HEADERS is defined
* configure.ac (guile_cv_localtime_cache): Rewrite preprocessor conditional block, assuming STDC_HEADERS is 1. * libguile/gen-scmconfig.c (SCM_HAVE_STDC_HEADERS): #define to 1 unconditionally. Rewrite preprocessor conditional block, assuming STDC_HEADERS is 1. * libguile/putenv.c: Rewrite preprocessor conditional block, assuming STDC_HEADERS is 1.
This commit is contained in:
parent
b03b0c7947
commit
4ba2d72b32
3 changed files with 9 additions and 21 deletions
|
@ -1080,9 +1080,7 @@ AC_MSG_CHECKING([whether localtime caches TZ])
|
|||
AC_CACHE_VAL([guile_cv_localtime_cache],
|
||||
[if test x$ac_cv_func_tzset = xyes; then
|
||||
AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <time.h>
|
||||
#if STDC_HEADERS
|
||||
#include <stdlib.h>
|
||||
#endif
|
||||
extern char **environ;
|
||||
unset_TZ ()
|
||||
{
|
||||
|
|
|
@ -157,7 +157,10 @@ main (int argc, char *argv[])
|
|||
#endif
|
||||
|
||||
pf("\n");
|
||||
#ifdef STDC_HEADERS
|
||||
/* The configure script used to check for and define STDC_HEADERS
|
||||
conditionally. Nowadays that is "obsolescent"
|
||||
(info "(autoconf) Particular Headers")
|
||||
but we define SCM_HAVE_STDC_HEADERS anyway for backward compat. */
|
||||
pf ("#define SCM_HAVE_STDC_HEADERS 1 /* 0 or 1 */\n");
|
||||
pf ("#include <stdlib.h>\n");
|
||||
#if HAVE_SYS_TYPES_H
|
||||
|
@ -167,9 +170,6 @@ main (int argc, char *argv[])
|
|||
pf ("#include <sys/stdtypes.h>\n");
|
||||
#endif
|
||||
pf ("#include <stddef.h>\n");
|
||||
#else /* STDC_HEADERS */
|
||||
pf ("#define SCM_HAVE_STDC_HEADERS 0 /* 0 or 1 */");
|
||||
#endif /* def STDC_HEADERS */
|
||||
|
||||
pf("\n");
|
||||
#ifdef HAVE_SYS_SELECT_H
|
||||
|
|
|
@ -35,17 +35,7 @@
|
|||
char *malloc ();
|
||||
#endif /* GNU C library. */
|
||||
|
||||
#if defined(STDC_HEADERS) || defined(HAVE_STRING_H)
|
||||
#include <string.h>
|
||||
#else
|
||||
#include <strings.h>
|
||||
#ifndef strchr
|
||||
#define strchr index
|
||||
#endif
|
||||
#ifndef memcpy
|
||||
#define memcpy(d, s, n) bcopy((s), (d), (n))
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue