Integrate changes from Google open-source branch.
diff --git a/configure.ac b/configure.ac
index d1fde9d..b68468e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -54,7 +54,7 @@
 AC_PROG_CXX
 AC_LANG([C++])
 ACX_USE_SYSTEM_EXTENSIONS
-AM_PROG_AR
+m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
 AM_CONDITIONAL(GCC, test "$GCC" = yes)   # let the Makefile know if we're gcc
 
 # test_util.cc takes forever to compile with GCC and optimization turned on.