Linux porting

Porting to linux
Reorganising the code
Improving the scan function
This commit is contained in:
2026-03-16 23:20:22 +01:00
parent ed0326d796
commit 7456b20fa3
8 changed files with 1043 additions and 1383 deletions

6
base.h
View File

@@ -146,6 +146,9 @@ static void plat_sem_destroy(plat_sem *s) {
}
}
// Sleep
static void sleep_ms(int ms) { Sleep(ms); }
#elif defined(__linux__)
// Memory allocation
@@ -211,4 +214,7 @@ static void plat_sem_post(plat_sem *s, u32 count) {
static void plat_sem_destroy(plat_sem *s) { sem_destroy(&s->sem); }
// Sleep
static void sleep_ms(int ms) { usleep(ms * 1000); }
#endif