Remove bundled m4 macros, use system's instead from dev-build/autoconf-archive.
The previous version of this patch required linking to boost::system to prevent
underlinking issues, but that is header-only since 1.69 with boost::system only
remaining as a stub library, and became fatal with Boost 1.89.
See also:
https://bugs.gentoo.org/550018
https://bugs.gentoo.org/963412

--- a/unix/configure.ac
+++ b/unix/configure.ac
@@ -54,23 +54,7 @@
 AC_CONFIG_SRCDIR([unix/disp_text.cpp])
 
 # Additional autoconf macros.
-m4_include([unix/config/acx_pthread.m4])
-m4_include([unix/config/ax_arg_enable.m4])
-m4_include([unix/config/ax_arg_with.m4])
-m4_include([unix/config/ax_boost_base.m4])
-m4_include([unix/config/ax_boost_thread.m4])
-m4_include([unix/config/ax_test_compiler_flags.m4])
-m4_include([unix/config/ax_check_lib.m4])
-m4_include([unix/config/ax_check_libjpeg.m4])
-m4_include([unix/config/ax_check_libsdl.m4])
-m4_include([unix/config/ax_check_libtiff.m4])
-m4_include([unix/config/ax_check_openexr.m4])
-m4_include([unix/config/ax_compare_version.m4])
-m4_include([unix/config/ax_compiler_vendor.m4])
-m4_include([unix/config/ax_compiler_version.m4])
-m4_include([unix/config/ax_fix_incorrect_path.m4])
-m4_include([unix/config/ax_prog_ld_static.m4])
-m4_include([unix/config/ax_x86_arch.m4])
+AC_CONFIG_MACRO_DIR([unix/config])
 
 # Required versions of the support libraries.
 # Must be declared after AC_INIT.
@@ -166,7 +150,7 @@
 AC_CANONICAL_BUILD
 AC_CANONICAL_HOST
 
-AM_INIT_AUTOMAKE([1.9 dist-bzip2])
+AM_INIT_AUTOMAKE([1.9 dist-bzip2 subdir-objects])
 AM_MAINTAINER_MODE
 
 AX_FIX_INCORRECT_PATH(C_INCLUDE_PATH, ".", [pov_warn_path="$pov_warn_path C_INCLUDE_PATH"])
@@ -184,6 +168,7 @@
 CFLAGS="$CFLAGS"
 AC_PROG_CC
 AC_PROG_CPP
+AM_PROG_AR
 
 # Force checking essential (ANSI-compliant) headers.
 AC_CHECK_HEADERS([stdlib.h])
@@ -292,7 +277,7 @@
 fi
 
 # Posix threads
-ACX_PTHREAD
+AX_PTHREAD
 CXXFLAGS="$CXXFLAGS $PTHREAD_CFLAGS"  # append
 LIBS="$LIBS $PTHREAD_CFLAGS $PTHREAD_LIBS"  # append
 
@@ -307,19 +292,6 @@
   LDFLAGS="$LDFLAGS $BOOST_LDFLAGS"     # append
   LIBS="$BOOST_THREAD_LIB $LIBS"
 fi
-AC_MSG_CHECKING([whether the boost thread library is usable])
-AC_RUN_IFELSE(
-  [AC_LANG_PROGRAM([[
-#include <boost/thread/thread.hpp>
-    ]],
-    [[boost::defer_lock_t(); return 0;]])],
-  [AC_MSG_RESULT([yes])],
-  [
-    AC_MSG_RESULT([no])
-    AC_MSG_FAILURE([cannot link with the boost thread library])
-  ],
-  [AC_MSG_RESULT([cross-compiling])]  # FIXME
-)
 AC_DEFINE([USE_OFFICIAL_BOOST], [], [Use the official Boost libraries.])
 
 # Intel Math Kernel library
--- a/vfe/unix/platformbase.cpp
+++ b/vfe/unix/platformbase.cpp
@@ -68,7 +68,7 @@
 #else
 		// taken from source/base/timer.cpp
 		boost::xtime t;
-		boost::xtime_get(&t, boost::TIME_UTC);
+		boost::xtime_get(&t, POV_TIME_UTC);
 		POV_ULONG ns = (POV_ULONG)(t.sec) * (POV_ULONG)(1000000000) + (POV_ULONG)(t.nsec) + (POV_ULONG)(msec) * (POV_ULONG)(1000000);
 		t.sec = (boost::xtime::xtime_sec_t)(ns / (POV_ULONG)(1000000000));
 		t.nsec = (boost::xtime::xtime_nsec_t)(ns % (POV_ULONG)(1000000000));
