Framework for exporting system header to user space (#59)
[lunaix-os.git] / lunaix-os / usr / libc / src / posix / lunaix.c
index 452f02ddbfd773a0ce88c1140f57d0e3cbbff1e9..deba1017108750057c8724a03f3950bcd670d02c 100644 (file)
@@ -1,23 +1,23 @@
-#include <lunaix/syscall.h>
-#include <lunaix/types.h>
+#include <syscall.h>
+#include <sys/types.h>
 #include <stdio.h>
 
 void
 yield()
 {
 #include <stdio.h>
 
 void
 yield()
 {
-    do_lunaix_syscall(__SYSCALL_yield);
+    do_lunaix_syscall(__NR__lxsys_yield);
 }
 
 pid_t
 wait(int* status)
 {
 }
 
 pid_t
 wait(int* status)
 {
-    return do_lunaix_syscall(__SYSCALL_wait, status);
+    return do_lunaix_syscall(__NR__lxsys_wait, status);
 }
 
 pid_t
 waitpid(pid_t pid, int* status, int options)
 {
 }
 
 pid_t
 waitpid(pid_t pid, int* status, int options)
 {
-    return do_lunaix_syscall(__SYSCALL_waitpid, pid, status, options);
+    return do_lunaix_syscall(__NR__lxsys_waitpid, pid, status, options);
 }
 
 void
 }
 
 void
@@ -28,7 +28,7 @@ syslog(int level, const char* fmt, ...)
     va_start(ap, fmt);
 
     unsigned int size = vsnprintf(buf, 1024, fmt, ap);
     va_start(ap, fmt);
 
     unsigned int size = vsnprintf(buf, 1024, fmt, ap);
-    do_lunaix_syscall(__SYSCALL_syslog, level, buf, size);
+    do_lunaix_syscall(__NR__lxsys_syslog, level, buf, size);
 
     va_end(ap);
 }
 
     va_end(ap);
 }
@@ -36,5 +36,5 @@ syslog(int level, const char* fmt, ...)
 int
 realpathat(int fd, char* buf, size_t size)
 {
 int
 realpathat(int fd, char* buf, size_t size)
 {
-    return do_lunaix_syscall(__SYSCALL_realpathat, fd, buf, size);
+    return do_lunaix_syscall(__NR__lxsys_realpathat, fd, buf, size);
 }
\ No newline at end of file
 }
\ No newline at end of file