Luna/libs/libc/src/luna.cpp

25 lines
479 B
C++
Raw Normal View History

#include <luna.h>
#include <luna/syscall.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/syscall.h>
extern "C"
{
long getprocid(int field)
{
return __lc_fast_syscall1(SYS_getprocid, field);
}
unsigned int msleep(unsigned int ms)
{
return (unsigned int)__lc_fast_syscall1(SYS_sleep, ms);
}
__lc_noreturn void __luna_abort(const char* message)
{
2022-10-12 09:54:29 +00:00
fputs(message, stderr);
abort();
}
}