summaryrefslogtreecommitdiff
path: root/libc/sysdeps/linux/common
diff options
context:
space:
mode:
Diffstat (limited to 'libc/sysdeps/linux/common')
-rw-r--r--libc/sysdeps/linux/common/fork.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/libc/sysdeps/linux/common/fork.c b/libc/sysdeps/linux/common/fork.c
index 88958b144..fa1f4affa 100644
--- a/libc/sysdeps/linux/common/fork.c
+++ b/libc/sysdeps/linux/common/fork.c
@@ -8,15 +8,15 @@
*/
#include <sys/syscall.h>
-#include <unistd.h>
-#ifdef __ARCH_USE_MMU__
-
-#ifdef __NR_fork
-#define __NR___libc_fork __NR_fork
-_syscall0(pid_t, __libc_fork)
-weak_alias(__libc_fork,fork)
+#if defined __NR_fork && defined __ARCH_USE_MMU__
+# include <unistd.h>
+# include <cancel.h>
+_syscall0(pid_t, fork)
+# ifdef __UCLIBC_HAS_THREADS__
+strong_alias(fork,__libc_fork)
libc_hidden_weak(fork)
-#endif
-
+# else
+libc_hidden_def(fork)
+# endif
#endif