diff --git a/src/configure.ac b/src/configure.ac
index 9a76644..1c89df1 100644
--- a/src/configure.ac
+++ b/src/configure.ac
@@ -19,8 +19,9 @@ dnl
 dnl You should have received a copy of the GNU General Public License
 dnl along with this program.  If not, see <https://www.gnu.org/licenses/>.
 
-AC_PREREQ([2.64])
-AC_INIT([main.cc])
+AC_PREREQ([2.69c])
+AC_INIT
+AC_CONFIG_SRCDIR([main.cc])
 AC_CONFIG_HEADERS([config.h])
 AC_PROG_MAKE_SET
 dnl
@@ -41,11 +42,13 @@ dnl           checks for compiler characteristics
 dnl
 AC_MSG_CHECKING([for stack-allocated variable-size arrays])
 AC_CACHE_VAL([gp_cv_cxx_dynamic_array], [
-AC_LANG_SAVE()
-AC_LANG_CPLUSPLUS()
-AC_TRY_COMPILE([int func (int n) { int dynamic_array[n]; }], [],
-  [gp_cv_cxx_dynamic_array=yes], [gp_cv_cxx_dynamic_array=no])
-AC_LANG_RESTORE()
+m4_warn([obsolete],
+[Instead of using `AC_LANG', `AC_LANG_SAVE', and `AC_LANG_RESTORE',
+you should use `AC_LANG_PUSH' and `AC_LANG_POP'.])dnl
+AC_LANG_SAVE
+AC_LANG([C++])
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[int func (int n) { int dynamic_array[n]; }]], [[]])],[gp_cv_cxx_dynamic_array=yes],[gp_cv_cxx_dynamic_array=no])
+AC_LANG_POP([])
 ])
 AC_MSG_RESULT([$gp_cv_cxx_dynamic_array])
 if test $gp_cv_cxx_dynamic_array = yes; then
@@ -63,4 +66,5 @@ AC_SUBST([GPERF_LIBM])
 dnl
 dnl           That's it.
 dnl
-AC_OUTPUT([Makefile])
+AC_CONFIG_FILES([Makefile])
+AC_OUTPUT
