From: =?utf-8?b?T25kxZllaiBTdXLDvQ==?= <ondrej@sury.org>
Date: Mon, 2 Dec 2024 21:03:24 +0100
Subject: Don't use uuid_time64(), it's not part of the API

---
 uuid-1.2.1/config.m4 |  1 -
 uuid-1.2.1/uuid.c    | 15 +--------------
 2 files changed, 1 insertion(+), 15 deletions(-)

diff --git a/uuid-1.2.1/config.m4 b/uuid-1.2.1/config.m4
index 8848748..ceef605 100644
--- a/uuid-1.2.1/config.m4
+++ b/uuid-1.2.1/config.m4
@@ -19,7 +19,6 @@ if test "$PHP_UUID" != "no"; then
   PHP_CHECK_FUNC_LIB(uuid_generate_md5, uuid)
   PHP_CHECK_FUNC_LIB(uuid_generate_sha1, uuid)
   PHP_CHECK_FUNC_LIB(uuid_time, uuid)
-  PHP_CHECK_FUNC_LIB(uuid_time64, uuid)
 
   export OLD_CPPFLAGS="$CPPFLAGS"
   export CPPFLAGS="$CPPFLAGS $INCLUDES -DHAVE_UUID"
diff --git a/uuid-1.2.1/uuid.c b/uuid-1.2.1/uuid.c
index ee782e4..f582b38 100644
--- a/uuid-1.2.1/uuid.c
+++ b/uuid-1.2.1/uuid.c
@@ -27,15 +27,6 @@
 
 #ifdef HAVE_UUID
 
-#if defined(uuid_time)
-/* workround with define uuid_time uuid_time64 */
-/* Also see https://bugzilla.redhat.com/2315645 */
-#undef uuid_time
-#if !defined(HAVE_UUID_TIME64)
-extern time_t uuid_time(const uuid_t uu, struct timeval *ret_tv);
-#endif
-#endif
-
 #if PHP_VERSION_ID < 80000
 #define VALUE_ERROR(n,name,msg) php_error_docref(NULL, E_WARNING, "Argument #%d (%s) %s", n, name, msg); RETURN_FALSE
 #define RETURN_THROWS() return
@@ -326,7 +317,7 @@ PHP_FUNCTION(uuid_variant)
 
 #endif /* HAVE_UUID_VARIANT */
 
-#if defined(HAVE_UUID_TIME) || defined(HAVE_UUID_TIME64)
+#if defined(HAVE_UUID_TIME)
 /* {{{ proto int uuid_time(string uuid)
   Extract creation time from a time based UUID as UNIX timestamp */
 PHP_FUNCTION(uuid_time)
@@ -353,11 +344,7 @@ PHP_FUNCTION(uuid_time)
 		VALUE_ERROR(1, "$uuid", "UUID DCE TIME expected");
 	}
 
-#if defined(HAVE_UUID_TIME64)
-	RETURN_LONG(uuid_time64(u, NULL));
-#else
 	RETURN_LONG(uuid_time(u, NULL));
-#endif
 }
 /* }}} uuid_time */
 #endif /* HAVE_UUID_TIME */
