feat: Integrate LVGL v8.3 desktop GUI, PS/2 mouse driver, live system monitor, and make gui target

This commit is contained in:
RarDog
2026-09-02 20:42:18 +03:00
parent c98c8de9d4
commit 78d38f7620
435 changed files with 286235 additions and 24 deletions
+12
View File
@@ -0,0 +1,12 @@
#pragma once
#include <stdint.h>
#define PRId64 "lld"
#define PRIu64 "llu"
#define PRIx64 "llx"
#define PRIX64 "llX"
#define PRId32 "d"
#define PRIu32 "u"
#define PRIx32 "x"
#define PRIX32 "X"
+4
View File
@@ -6,8 +6,12 @@ typedef __INTPTR_TYPE__ intptr_t;
typedef __UINTPTR_TYPE__ uintptr_t;
#ifndef NULL
#ifdef __cplusplus
#define NULL 0
#else
#define NULL ((void*)0)
#endif
#endif
#ifndef offsetof
#define offsetof(type, member) __builtin_offsetof(type, member)
+14
View File
@@ -13,6 +13,19 @@ typedef __UINT64_TYPE__ uint64_t;
typedef __INTPTR_TYPE__ intptr_t;
typedef __UINTPTR_TYPE__ uintptr_t;
typedef __INTMAX_TYPE__ intmax_t;
typedef __UINTMAX_TYPE__ uintmax_t;
typedef int32_t int_fast32_t;
typedef uint32_t uint_fast32_t;
typedef int16_t int_fast16_t;
typedef uint16_t uint_fast16_t;
#define INT8_MIN (-128)
#define INT16_MIN (-32768)
#define INT32_MIN (-2147483647 - 1)
#define INT64_MIN (-9223372036854775807LL - 1)
#define INT8_MAX 127
#define INT16_MAX 32767
#define INT32_MAX 2147483647
@@ -22,3 +35,4 @@ typedef __UINTPTR_TYPE__ uintptr_t;
#define UINT16_MAX 65535
#define UINT32_MAX 4294967295U
#define UINT64_MAX 18446744073709551615ULL
#define SIZE_MAX ((size_t)-1)
+1
View File
@@ -11,6 +11,7 @@ int puts(const char *s);
int putchar(int c);
int printf(const char *format, ...);
int sprintf(char *str, const char *format, ...);
int snprintf(char *str, size_t size, const char *format, ...);
#ifdef __cplusplus
}
+2
View File
@@ -15,6 +15,8 @@ void *realloc(void *ptr, size_t size);
void abort(void);
void exit(int status);
int atoi(const char *nptr);
static inline int abs(int x) { return x < 0 ? -x : x; }
static inline long labs(long x) { return x < 0 ? -x : x; }
#ifdef __cplusplus
}
+1
View File
@@ -17,6 +17,7 @@ int strcmp(const char *s1, const char *s2);
int strncmp(const char *s1, const char *s2, size_t n);
char *strcpy(char *dest, const char *src);
char *strncpy(char *dest, const char *src, size_t n);
char *strcat(char *dest, const char *src);
char *strchr(const char *s, int c);
char *strstr(const char *haystack, const char *needle);
+9
View File
@@ -91,6 +91,15 @@ char *strncpy(char *dest, const char *src, size_t n) {
return ret;
}
char *strcat(char *dest, const char *src) {
char *ret = dest;
while (*dest) {
dest++;
}
while ((*dest++ = *src++));
return ret;
}
char *strchr(const char *s, int c) {
char ch = (char)c;
while (*s) {
+8
View File
@@ -133,6 +133,14 @@ int sprintf(char *buf, const char *fmt, ...) {
return ret;
}
int snprintf(char *buf, size_t size, const char *fmt, ...) {
__builtin_va_list args;
__builtin_va_start(args, fmt);
int ret = vsnprintf(buf, size, fmt, args);
__builtin_va_end(args);
return ret;
}
int printf(const char *fmt, ...) {
char buf[2048];
__builtin_va_list args;