[Gmp-commit] /var/hg/gmp: Drop AC_HEADER_STDC and AC_HEADER_TIME
mercurial at gmplib.org
mercurial at gmplib.org
Mon Aug 21 12:00:44 CEST 2023
details: /var/hg/gmp/rev/40680ec7428b
changeset: 18439:40680ec7428b
user: Marc Glisse <marc.glisse at inria.fr>
date: Mon Aug 21 12:00:39 2023 +0200
description:
Drop AC_HEADER_STDC and AC_HEADER_TIME
diffstat:
ChangeLog | 6 ++++++
configure.ac | 18 +++---------------
tests/misc.c | 10 ++--------
tune/freq.c | 10 ++--------
tune/speed.c | 10 ++--------
tune/time.c | 10 ++--------
6 files changed, 17 insertions(+), 47 deletions(-)
diffs (132 lines):
diff -r 798ca4da0556 -r 40680ec7428b ChangeLog
--- a/ChangeLog Sun Aug 20 03:18:25 2023 +0200
+++ b/ChangeLog Mon Aug 21 12:00:39 2023 +0200
@@ -1,3 +1,9 @@
+2023-08-21 FX Coudert <fxcoudert at gmail.com>
+
+ * configure.ac: Drop AC_HEADER_STDC and AC_HEADER_TIME.
+ * configure.ac, tests/misc.c, tune/freq.c, tune/speed.c, tune/time.c:
+ Unconditionally include time.h.
+
2023-08-19 Marc Glisse <marc.glisse at inria.fr>
* doc/gmp.texi: Rename IEEE P754. Remove @refill.
diff -r 798ca4da0556 -r 40680ec7428b configure.ac
--- a/configure.ac Sun Aug 20 03:18:25 2023 +0200
+++ b/configure.ac Mon Aug 21 12:00:39 2023 +0200
@@ -2830,12 +2830,6 @@
AM_CONDITIONAL(ENABLE_STATIC, test "$enable_static" = yes)
-# Many of these library and header checks are for the benefit of
-# supplementary programs. libgmp doesn't use anything too weird.
-
-AC_HEADER_STDC
-AC_HEADER_TIME
-
# Reasons for testing:
# float.h - not in SunOS bundled cc
# invent.h - IRIX specific
@@ -2865,15 +2859,9 @@
# On SunOS, sys/resource.h needs sys/time.h (for struct timeval)
AC_CHECK_HEADERS(sys/resource.h,,,
-[#if TIME_WITH_SYS_TIME
-# include <sys/time.h>
-# include <time.h>
-#else
-# if HAVE_SYS_TIME_H
-# include <sys/time.h>
-# else
-# include <time.h>
-# endif
+[#include <time.h>
+#if HAVE_SYS_TIME_H
+# include <sys/time.h> /* for struct timeval */
#endif])
# On NetBSD and OpenBSD, sys/sysctl.h needs sys/param.h for various constants
diff -r 798ca4da0556 -r 40680ec7428b tests/misc.c
--- a/tests/misc.c Sun Aug 20 03:18:25 2023 +0200
+++ b/tests/misc.c Mon Aug 21 12:00:39 2023 +0200
@@ -29,15 +29,9 @@
#include <float.h> /* for DBL_MANT_DIG */
#endif
-#if TIME_WITH_SYS_TIME
+#include <time.h>
+#if HAVE_SYS_TIME_H
# include <sys/time.h> /* for struct timeval */
-# include <time.h>
-#else
-# if HAVE_SYS_TIME_H
-# include <sys/time.h>
-# else
-# include <time.h>
-# endif
#endif
#include "gmp-impl.h"
diff -r 798ca4da0556 -r 40680ec7428b tune/freq.c
--- a/tune/freq.c Sun Aug 20 03:18:25 2023 +0200
+++ b/tune/freq.c Mon Aug 21 12:00:39 2023 +0200
@@ -96,15 +96,9 @@
#include <sys/sysctl.h> /* for sysctlbyname() */
#endif
-#if TIME_WITH_SYS_TIME
+#include <time.h>
+#if HAVE_SYS_TIME_H
# include <sys/time.h> /* for struct timeval */
-# include <time.h>
-#else
-# if HAVE_SYS_TIME_H
-# include <sys/time.h>
-# else
-# include <time.h>
-# endif
#endif
#if HAVE_SYS_RESOURCE_H
diff -r 798ca4da0556 -r 40680ec7428b tune/speed.c
--- a/tune/speed.c Sun Aug 20 03:18:25 2023 +0200
+++ b/tune/speed.c Mon Aug 21 12:00:39 2023 +0200
@@ -51,15 +51,9 @@
#include <unistd.h> /* for getpid, R_OK */
#endif
-#if TIME_WITH_SYS_TIME
+#include <time.h>
+#if HAVE_SYS_TIME_H
# include <sys/time.h> /* for struct timeval */
-# include <time.h>
-#else
-# if HAVE_SYS_TIME_H
-# include <sys/time.h>
-# else
-# include <time.h>
-# endif
#endif
#if HAVE_SYS_RESOURCE_H
diff -r 798ca4da0556 -r 40680ec7428b tune/time.c
--- a/tune/time.c Sun Aug 20 03:18:25 2023 +0200
+++ b/tune/time.c Mon Aug 21 12:00:39 2023 +0200
@@ -176,15 +176,9 @@
#include <sys/types.h>
-#if TIME_WITH_SYS_TIME
+#include <time.h>
+#if HAVE_SYS_TIME_H
# include <sys/time.h> /* for struct timeval */
-# include <time.h>
-#else
-# if HAVE_SYS_TIME_H
-# include <sys/time.h>
-# else
-# include <time.h>
-# endif
#endif
#if HAVE_SYS_MMAN_H
More information about the gmp-commit
mailing list