From 1dd52ab472e9dffa0cbdcdc68f196b64ce2abfc4 Mon Sep 17 00:00:00 2001 From: Paul Smith Date: Fri, 28 Oct 2022 13:03:18 -0400 Subject: Avoid C99 constructs Although gnulib requires C99, most of the code does compile with a C90 compiler (perhaps with a lot of warnings). Reinstate our C90 configuration test, and clean up a few C99 things that crept in. * src/job.c (construct_command_argv_internal): Don't use loop-local variables or C++ comments. * src/read.c (eval_makefile): Don't use loop-local variables. --- maintMakefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'maintMakefile') diff --git a/maintMakefile b/maintMakefile index fb98a42f..b9f822ad 100644 --- a/maintMakefile +++ b/maintMakefile @@ -259,7 +259,8 @@ CFGCHECK_BUILDFLAGS = # as well, and that will fail. CFGCHECK_MAKEFLAGS = # CFLAGS='$(AM_CFLAGS)' -# This test can no longer be run: now that we rely on gnulib we must use C99+ +# We don't support C90 anymore, strictly, but this test still works (with lots +# of warnings) and it helps us avoid egregious incompatibilities. checkcfg.strict-c90: CFGCHECK_CONFIGFLAGS = CFLAGS='-std=c90 -pedantic' checkcfg.strict-c90: CFGCHECK_MAKEFLAGS = @@ -277,6 +278,7 @@ checkcfg.no-sync: CFGCHECK_CONFIGFLAGS = CPPFLAGS=-DNO_OUTPUT_SYNC checkcfg.no-archives: CFGCHECK_CONFIGFLAGS = CPPFLAGS=-DNO_ARCHIVES CONFIG_CHECKS := \ + checkcfg.strict-c90 \ checkcfg.no-jobserver \ checkcfg.no-load \ checkcfg.no-guile \ -- cgit v1.2.1