No prctl(2). No EBADFD. Rename pw_init()/pw_deinit(): they clash with
libutil on OpenBSD and FreeBSD.
https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/1819

Index: src/pipewire/pipewire.c
--- src/pipewire/pipewire.c.orig
+++ src/pipewire/pipewire.c
@@ -7,7 +7,7 @@
 #include <unistd.h>
 #include <limits.h>
 #include <stdio.h>
-#if !defined(__FreeBSD__) && !defined(__MidnightBSD__) && !defined(__GNU__)
+#if !defined(__FreeBSD__) && !defined(__MidnightBSD__) && !defined(__OpenBSD__) && !defined(__GNU__)
 #include <sys/prctl.h>
 #endif
 #include <pwd.h>
@@ -310,7 +310,11 @@ struct spa_handle *pw_load_spa_handle(const char *lib,
 error:
 	pw_log_error("load lib: pw_init() was not called");
 	pthread_mutex_unlock(&support_lock);
+#ifdef __linux__
 	errno = EBADFD;
+#else
+	errno = EBADF;
+#endif
 	return NULL;
 }
 
@@ -495,7 +499,7 @@ static struct spa_log *load_journal_logger(struct supp
  * This function can be called multiple times.
  */
 SPA_EXPORT
-void pw_init(int *argc, char **argv[])
+void pipewire_init(int *argc, char **argv[])
 {
 	const char *str;
 	struct spa_dict_item items[6];
@@ -610,7 +614,7 @@ done:
  * used again after being deinitialized with a new pw_init() call.
  */
 SPA_EXPORT
-void pw_deinit(void)
+void pipewire_deinit(void)
 {
 	struct support *support = &global_support;
 	struct registry *registry = &support->registry;
@@ -636,6 +640,21 @@ done:
 
 }
 
+#if !defined(__FreeBSD__) && !defined(__OpenBSD__)
+#undef pw_init
+SPA_EXPORT
+void pw_init(int *argc, char **argv[])
+{
+	pipewire_init(argc, argv);
+}
+#undef pw_deinit
+SPA_EXPORT
+void pw_deinit(void)
+{
+	pipewire_deinit();
+}
+#endif
+
 /** Check if a debug category is enabled
  *
  * \param name the name of the category to check
@@ -683,7 +702,7 @@ static void init_prgname(void)
 		}
 	}
 #endif
-#if !defined(__FreeBSD__) && !defined(__MidnightBSD__) && !defined(__GNU__)
+#if !defined(__FreeBSD__) && !defined(__MidnightBSD__) && !defined(__OpenBSD__) && !defined(__GNU__)
 	{
 		if (prctl(PR_GET_NAME, (unsigned long) name, 0, 0, 0) == 0) {
 			prgname = name;
