Skip to content

Commit

Permalink
Add patches for fixing macOS builds
Browse files Browse the repository at this point in the history
Signed-off-by: falkTX <[email protected]>
  • Loading branch information
falkTX committed Oct 29, 2023
1 parent c7aa81e commit 90ee565
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
13 changes: 13 additions & 0 deletions plugins/package/modspectre/01_fix-macos-build.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/src/ringbuf.h b/src/ringbuf.h
index 7f660ff..ed466c2 100644
--- a/src/ringbuf.h
+++ b/src/ringbuf.h
@@ -20,7 +20,7 @@
#include <stdlib.h>
#include <sys/types.h>

-#if defined __ATOMIC_SEQ_CST
+#if defined __ATOMIC_SEQ_CST && ! defined __APPLE__

#define _atomic_int_get(P) __atomic_load_4 (&(P), __ATOMIC_SEQ_CST)
#define _atomic_int_set(P, V) __atomic_store_4 (&(P), (V), __ATOMIC_SEQ_CST)
15 changes: 15 additions & 0 deletions plugins/package/notes-lv2/02_fix-macos-build.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
diff --git a/notes.c b/notes.c
index 6af3c4d..bf190ff 100644
--- a/notes.c
+++ b/notes.c
@@ -27,6 +27,10 @@
#include <pthread.h>
#include <inttypes.h>

+#ifdef __APPLE__
+#include <libgen.h>
+#endif
+
#include <notes.h>
#include <props.h>

0 comments on commit 90ee565

Please sign in to comment.