0
0
mirror of https://github.com/termux/termux-packages.git synced 2024-11-27 06:18:57 +00:00
termux-packages/ndk-patches/27c/semaphore.h.patch
2024-11-09 10:24:50 +08:00

19 lines
555 B
Diff

--- ./usr/include/semaphore.h.orig
+++ ./usr/include/semaphore.h
@@ -71,9 +71,14 @@
int sem_trywait(sem_t* _Nonnull __sem);
int sem_wait(sem_t* _Nonnull __sem);
-/* These aren't actually implemented. */
+#undef sem_open
+#define sem_open libandroid_sem_open
sem_t* _Nullable sem_open(const char* _Nonnull __name, int _flags, ...);
+#undef sem_close
+#define sem_close libandroid_sem_close
int sem_close(sem_t* _Nonnull __sem);
+#undef sem_unlink
+#define sem_unlink libandroid_sem_unlink
int sem_unlink(const char* _Nonnull __name);
__END_DECLS