 +}
  #endif
 diff --git a/src/funopen.c b/src/funopen.c
-index 1e05c7e..ed8ce85 100644
+index 1e05c7e..75e61ea 100644
 --- a/src/funopen.c
 +++ b/src/funopen.c
-@@ -137,7 +137,7 @@ funopen(const void *cookie,
- 
- 	return fopencookie(cookiewrap, mode, funcswrap);
- }
--#elif defined(__MUSL__)
-+#elif defined(__MUSL__) || defined(darwin) || defined(__APPLE__) || defined(MACOSX)
- /*
-  * This is unimplementable on musl based systems, and upstream has stated
+@@ -143,6 +143,7 @@ funopen(const void *cookie,
   * they will not add the needed support to implement it. Just ignore this
+  * interface there, as it has never been provided anyway.
+  */
++#elif defined(darwin) || defined(__APPLE__) || defined(MACOSX)
+ #else
+ #error "Function funopen() needs to be ported or disabled."
+ #endif
 diff --git a/src/getentropy.c b/src/getentropy.c
 index 3f11a1e..8a23a07 100644
 --- a/src/getentropy.c

 #include <sys/types.h>
 #include <stdint.h>
diff --git a/include/bsd/stdio.h b/include/bsd/stdio.h
index 4b69983..8e2ac75 100644
--- a/include/bsd/stdio.h
+++ b/include/bsd/stdio.h
@@ -48,12 +48,16 @@

diff --git a/configure.ac b/configure.ac
index 88ccd91..0857782 100644
--- a/configure.ac
+++ b/configure.ac
@@ -59,7 +59,7 @@ AS_CASE([$host_os],
