This commit is contained in:
Бранимир Караџић
2024-06-16 15:53:44 -07:00
parent 747e6b77eb
commit 03fe74eafb
10 changed files with 44 additions and 39 deletions

View File

@@ -11,7 +11,7 @@
#if BX_CRT_NONE
#include "crt0.h"
#include <bx/crt0.h>
#define NOT_IMPLEMENTED() \
{ bx::debugPrintf("crtnone: %s not implemented\n", BX_FUNCTION); abort(); }
@@ -511,6 +511,18 @@ extern "C" int prctl(int _option, unsigned long _arg2, unsigned long _arg3, unsi
return -1;
}
extern "C" int getpid()
{
return crt0::processGetId();
}
extern "C" ssize_t readlink(const char* _pathName, char* _buffer, size_t _bufferSize)
{
BX_UNUSED(_pathName, _buffer, _bufferSize);
NOT_IMPLEMENTED();
return 0;
}
extern "C" int chdir(const char* _path)
{
BX_UNUSED(_path);
@@ -635,6 +647,16 @@ void operator delete(void*, size_t)
{
}
extern "C" void* __cxa_begin_catch(void* _unwindArg)
{
BX_UNUSED(_unwindArg);
return NULL;
}
extern "C" void __cxa_end_catch()
{
}
extern "C" void __cxa_pure_virtual(void)
{
}