Browse Source

symlink.c: Compile only if syscall is available

Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Peter S. Mazinger 14 years ago
parent
commit
c292baef29
1 changed files with 3 additions and 2 deletions
  1. 3 2
      libc/sysdeps/linux/common/symlink.c

+ 3 - 2
libc/sysdeps/linux/common/symlink.c

@@ -8,7 +8,8 @@
  */
 
 #include <sys/syscall.h>
-#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K
-#include <unistd.h>
+
+#if defined __NR_symlink && (defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K)
+# include <unistd.h>
 _syscall2(int, symlink, const char *, oldpath, const char *, newpath)
 #endif