summaryrefslogtreecommitdiff
path: root/dev-lua/lanes/files/lanes-3.16.2-musl.patch
diff options
context:
space:
mode:
Diffstat (limited to 'dev-lua/lanes/files/lanes-3.16.2-musl.patch')
-rw-r--r--dev-lua/lanes/files/lanes-3.16.2-musl.patch27
1 files changed, 27 insertions, 0 deletions
diff --git a/dev-lua/lanes/files/lanes-3.16.2-musl.patch b/dev-lua/lanes/files/lanes-3.16.2-musl.patch
new file mode 100644
index 000000000000..05508a57d85d
--- /dev/null
+++ b/dev-lua/lanes/files/lanes-3.16.2-musl.patch
@@ -0,0 +1,27 @@
+From 0e959e637b6ee85b0710e0608fe5d678ad7e0b78 Mon Sep 17 00:00:00 2001
+From: Conrad Kostecki <conikost@gentoo.org>
+Date: Tue, 23 Jan 2024 21:58:50 +0100
+Subject: [PATCH] src/threading.h: fix compilation on musl
+
+Signed-off-by: Conrad Kostecki <conikost@gentoo.org>
+---
+ src/threading.h | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/src/threading.h b/src/threading.h
+index 3925076..b1706ac 100644
+--- a/src/threading.h
++++ b/src/threading.h
+@@ -113,7 +113,11 @@ enum e_status { PENDING, RUNNING, WAITING, DONE, ERROR_ST, CANCELLED };
+ #include <pthread.h>
+
+ #ifdef PLATFORM_LINUX
+- # define _MUTEX_RECURSIVE PTHREAD_MUTEX_RECURSIVE_NP
++ #if defined(__GLIBC__)
++ # define _MUTEX_RECURSIVE PTHREAD_MUTEX_RECURSIVE_NP
++ #else
++ # define _MUTEX_RECURSIVE PTHREAD_MUTEX_RECURSIVE
++ #endif
+ #else
+ /* OS X, ... */
+ # define _MUTEX_RECURSIVE PTHREAD_MUTEX_RECURSIVE