0
0
mirror of https://github.com/termux/termux-packages.git synced 2024-11-23 14:56:16 +00:00
termux-packages/ndk-patches/23c/semaphore.h.patch
Henrik Grimler e7f4ad8b6d
scripts: rename termux_step_setup_toolchain to indicate NDK version
And keep ndk-patches in 23c/ subdirectory.  Run
termux_step_setup_toolchain_23c only if TERMUX_NDK_VERSION equals 23c.

This is a step towards having the possibility to use different NDK
versions.  Using a different NDK version than the one termux
officially supports should *really* not be done except for
testing/debug/development reasons, or if it is strictly necessary to
be able to compile a program (for example for packages that need a
fortran compiler, which at the moment is only supported with old
gcc-using NDKs).
2022-08-13 12:19:59 +02:00

19 lines
500 B
Diff

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