Alguém sabe como fazer um sistema operacional ou já fez antes? eu estou fazendo do zero e estou programando em cpp, alguém sabe como me ajudar, alguém mais poderia me dar umas dicas de como se faz? eu prefiro fazer por partes, eu já desenvolvi o Kernel, e agora estou fazendo um Bootloader personalizado, alguém mais sabe como? eu tenho certos erros como em umas das fotos abaixo, alguém mais sabe como resolver?
#include <cstdint>
#include <cstddef>
typedef int id_t;
typedef int uint64_t_syscall_ulong_t;
typedef int uint64_t_fsblkcnt64_t;
typedef int uint64_t_fsblkcnt_t;
extern "C"
int initstate(id_t id);
int initstate_r(id_t id);
int fast16_t_getcpu(void);
int fast32_t_system_call_32(void);
int fast64_t_system_call_64(void);
int least16_t_system_getcpu(void);
int least32_t_system_add_kernel(void);
int least64_t_system_get_kernel_info(void);
#include <cstdint>
#include <stddef.h>
typedef int id_t;
typedef int uint64_t_syscall_ulong_t;
typedef int uint64_t_fsblkcnt64_t;
typedef int uint64_t_fsblkcnt_t;
extern "C"
int initstate(id_t id);
int initstate_r(id_t id);
int fast16_t_getcpu(void);
int fast32_t_system_call_32(void);
int fast64_t_system_call_64(void);
int least16_t_system_getcpu(void);
int least32_t_system_add_kernel(void);
int least64_t_system_get_kernel_info(void);
int fsblkcnt64_t_syscall_ext4(__syscall_ulong_t arg);
int fsblkcnt_t_syscall_base_t(__syscall_ulong_t arg);
struct Registers
extern "C"
uint32_t edi, esi, ebp, esp, eax, ebx, edx, ecx;
uint32_t eip, eflags, useresp, ss, cs;
struct Task {
uint32_t stack_pointer
uint32_t id;
bool active;
Task task_list[2];
int current_task_index = 0;
// Per-process state
struct proc {
uint sz; // Size of process memory (bytes)
pde_t* pgdir; // Page Table
char *kstack; // Bottom of Kernel Stack for this process
enum procstate state; // Process state
volatile int pid; // Process ID
struct proc *parent; // Parent process
struct trapframe *tf; // Trap frame for current syscall
struct context *context // swtch() here to run process
void *chan; // If non-zero, sleeping on chan
int killed; // If non-zero, have been killed
struct file *ofile[NOFILE] // Open files
struct inode *cwd; // Current directory
char name[16]; // Process name (debugging)
};

