$OpenBSD: patch-configure_ac,v 1.6 2021/11/24 15:35:20 kmos Exp $

#1: Set ports library version
#2: Don't pick up an installed linux/e2fsprogs libuuid.so
#3: OpenBSD isn't multi-arch

Index: configure.ac
--- configure.ac.orig
+++ configure.ac
@@ -126,7 +126,7 @@ VERSION=PYTHON_VERSION
 
 # Version number of Python's own shared library file.
 AC_SUBST(SOVERSION)
-SOVERSION=1.0
+SOVERSION=${LIBpython3.9_VERSION}
 
 # The later defininition of _XOPEN_SOURCE disables certain features
 # on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone).
@@ -740,8 +740,8 @@ cat >> conftest.c <<EOF
 #undef powerpc
 #undef sparc
 #undef unix
-#if defined(__ANDROID__)
-    # Android is not a multiarch system.
+#if defined(__ANDROID__) || defined(__OpenBSD__)
+    # Neither Android nor OpenBSD are multiarch systems.
 #elif defined(__linux__)
 # if defined(__x86_64__) && defined(__LP64__)
         x86_64-linux-gnu
@@ -883,7 +883,7 @@ fi
 rm -f conftest.c conftest.out
 
 if test x$PLATFORM_TRIPLET != xdarwin; then
-  MULTIARCH=$($CC --print-multiarch 2>/dev/null)
+  MULTIARCH=$(false)
 fi
 AC_SUBST(MULTIARCH)
 
@@ -2860,18 +2860,7 @@ AC_CHECK_LIB(dl, dlopen)	# Dynamic linking for SunOS/S
 AC_CHECK_LIB(dld, shl_load)	# Dynamic linking for HP-UX
 
 # checks for uuid.h location
-AC_CHECK_HEADERS([uuid/uuid.h uuid.h])
-
-AC_MSG_CHECKING(for uuid_generate_time_safe)
-AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <uuid/uuid.h>]], [[
-#ifndef uuid_generate_time_safe
-void *x = uuid_generate_time_safe
-#endif
-]])],
-  [AC_DEFINE(HAVE_UUID_GENERATE_TIME_SAFE, 1, Define if uuid_generate_time_safe() exists.)
-   AC_MSG_RESULT(yes)],
-  [AC_MSG_RESULT(no)]
-)
+AC_CHECK_HEADERS([uuid.h])
 
 # check for libuuid from util-linux
 save_LIBS=$LIBS
