Skip to content

Commit

Permalink
autotools: revert '-std=gnu89' (commit f310326)
Browse files Browse the repository at this point in the history
Apparently commit e2e868d fixed the remaining issues with gcc 5.x.
See also #1093, e2e868d,
and f310326.
  • Loading branch information
claudioandre-br committed Jun 24, 2023
1 parent 4ae97fa commit ad83818
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 51 deletions.
49 changes: 0 additions & 49 deletions src/configure
Original file line number Diff line number Diff line change
Expand Up @@ -6900,55 +6900,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu


fi
if test 1 -gt 0; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -std=gnu89" >&5
$as_echo_n "checking if $CC supports -std=gnu89... " >&6; }
fi
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu

ac_saved_cflags="$CFLAGS"
CFLAGS="-Werror -std=gnu89"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */

int
main ()
{

;
return 0;
}
_ACEOF
if ac_fn_c_try_compile "$LINENO"; then :
if test "1" -gt 0; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
fi
CFLAGS_EX="$CFLAGS_EX -std=gnu89"

else
if test 1 -gt 0; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
fi
if test "1" = 2; then :
as_fn_error $? "Not supported by compiler" "$LINENO" 5
fi

fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
CFLAGS="$ac_saved_cflags"
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu


if test 1 -gt 0; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wdate-time" >&5
$as_echo_n "checking if $CC supports -Wdate-time... " >&6; }
Expand Down
2 changes: 0 additions & 2 deletions src/configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -269,8 +269,6 @@ fi
JTR_FLAG_CHECK([-Wunused-but-set-variable], 1)
dnl JTR_NOWARN_CHECK([unneeded-internal-declaration], 1)
AS_IF([test "x$JTR_FLAG_Q_CHECK_WORKS" = xyes], [JTR_FLAG_CHECK([-Qunused-arguments],1)])
dnl Justified and Ancient (see issue 1093)
JTR_FLAG_CHECK([-std=gnu89], 1)
dnl We like reproducible builds
JTR_FLAG_CHECK([-Wdate-time], 1)
JTR_LIST_ADD(CFLAGS_EXTRA, ["$CFLAGS_EX"])
Expand Down

0 comments on commit ad83818

Please sign in to comment.