unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
* bug#60022: configure.ac fix for C99 compatibility
@ 2022-12-12 21:35 Florian Weimer
  2023-01-16 22:19 ` Ludovic Courtès
  0 siblings, 1 reply; 2+ messages in thread
From: Florian Weimer @ 2022-12-12 21:35 UTC (permalink / raw)
  To: 60022

This patch is needed to improve C99 compatibility:

diff --git a/configure.ac b/configure.ac
index b3879df1f..cc865a028 100644
--- a/configure.ac
+++ b/configure.ac
@@ -904,7 +904,7 @@ AC_CACHE_VAL(guile_cv_localtime_cache,
 AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <time.h>
 #include <stdlib.h>
 extern char **environ;
-unset_TZ ()
+int unset_TZ ()
 {
   char **from, **to;
   for (to = from = environ; (*to = *from); from++)
@@ -913,7 +913,7 @@ unset_TZ ()
 }
 char TZ_GMT0[] = "TZ=GMT0";
 char TZ_PST8[] = "TZ=PST8";
-main()
+int main()
 {
   time_t now = time ((time_t *) 0);
   int hour_GMT0, hour_unset;

Future compilers are likely to reject implicit int types by default.

Found via:

  <https://fedoraproject.org/wiki/Changes/PortingToModernC>
  <https://fedoraproject.org/wiki/Toolchain/PortingToModernC>

Thanks,
Florian






^ permalink raw reply related	[flat|nested] 2+ messages in thread

* bug#60022: configure.ac fix for C99 compatibility
  2022-12-12 21:35 bug#60022: configure.ac fix for C99 compatibility Florian Weimer
@ 2023-01-16 22:19 ` Ludovic Courtès
  0 siblings, 0 replies; 2+ messages in thread
From: Ludovic Courtès @ 2023-01-16 22:19 UTC (permalink / raw)
  To: Florian Weimer; +Cc: 60022-done

Hi Florian,

Florian Weimer <fweimer@redhat.com> skribis:

> This patch is needed to improve C99 compatibility:
>
> diff --git a/configure.ac b/configure.ac
> index b3879df1f..cc865a028 100644
> --- a/configure.ac
> +++ b/configure.ac

Applied, thanks.

Ludo’.





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-01-16 22:19 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-12-12 21:35 bug#60022: configure.ac fix for C99 compatibility Florian Weimer
2023-01-16 22:19 ` Ludovic Courtès

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).