initial implementation of klibc

fix linker error about ctx_switch
This commit is contained in:
Borna Šoštarić
2025-12-27 11:19:42 +01:00
parent d83e247bbd
commit f30be3ddd5
15 changed files with 198 additions and 135 deletions

14
klibc/include/stdarg.h Normal file
View File

@@ -0,0 +1,14 @@
#ifndef CLASSICOS_KLIBC_STDARG_H
#define CLASSICOS_KLIBC_STDARG_H
typedef __builtin_va_list va_list;
#ifndef va_start
#define va_start(ap, param) __builtin_va_start(ap, param)
#endif
#define va_end(ap) __builtin_va_end(ap)
#define va_arg(ap, type) __builtin_va_arg(ap, type)
#define va_copy(dest, src) __builtin_va_copy(dest, src)
#endif // CLASSICOS_KLIBC_STDARG_H