autoconf: 1999-01-01 Ben Elliston <bje@cygnus.com>

https://github.com/libsdl-org/autoconf/commit/8d15cc94264d36d8a11354c3e100bd691df05c3e

From 8d15cc94264d36d8a11354c3e100bd691df05c3e Mon Sep 17 00:00:00 2001
From: Ben Elliston <[EMAIL REDACTED]>
Date: Thu, 31 Dec 1998 18:48:05 +0000
Subject: [PATCH] 1999-01-01  Ben Elliston  <bje@cygnus.com> 	*
 acspecific.m4 (AC_PROG_CXX_WORKS): Specify an explicit return 	type for
 `main' to keep modern C++ compilers happy.

---
 ChangeLog                | 5 +++++
 acspecific.m4            | 2 +-
 lib/autoconf/specific.m4 | 2 +-
 3 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 4769c70c..a65fb247 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+1999-01-01  Ben Elliston  <bje@cygnus.com>
+
+	* acspecific.m4 (AC_PROG_CXX_WORKS): Specify an explicit return
+	type for `main' to keep modern C++ compilers happy.
+
 1998-12-27  Ben Elliston  <bje@cygnus.com>
 
 	* autoconf.texi (AC_PROG_INSTALL): Update.
diff --git a/acspecific.m4 b/acspecific.m4
index 66142d24..0b9aab74 100644
--- a/acspecific.m4
+++ b/acspecific.m4
@@ -217,7 +217,7 @@ AC_DEFUN(AC_PROG_CXX_WORKS,
 [AC_MSG_CHECKING([whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works])
 AC_LANG_SAVE
 AC_LANG_CPLUSPLUS
-AC_TRY_COMPILER([main(){return(0);}], ac_cv_prog_cxx_works, ac_cv_prog_cxx_cross)
+AC_TRY_COMPILER([int main(){return(0);}], ac_cv_prog_cxx_works, ac_cv_prog_cxx_cross)
 AC_LANG_RESTORE
 AC_MSG_RESULT($ac_cv_prog_cxx_works)
 if test $ac_cv_prog_cxx_works = no; then
diff --git a/lib/autoconf/specific.m4 b/lib/autoconf/specific.m4
index 66142d24..0b9aab74 100644
--- a/lib/autoconf/specific.m4
+++ b/lib/autoconf/specific.m4
@@ -217,7 +217,7 @@ AC_DEFUN(AC_PROG_CXX_WORKS,
 [AC_MSG_CHECKING([whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works])
 AC_LANG_SAVE
 AC_LANG_CPLUSPLUS
-AC_TRY_COMPILER([main(){return(0);}], ac_cv_prog_cxx_works, ac_cv_prog_cxx_cross)
+AC_TRY_COMPILER([int main(){return(0);}], ac_cv_prog_cxx_works, ac_cv_prog_cxx_cross)
 AC_LANG_RESTORE
 AC_MSG_RESULT($ac_cv_prog_cxx_works)
 if test $ac_cv_prog_cxx_works = no; then