Use C for syscalls

This commit is contained in:
Kitsu
2021-12-09 02:18:30 +03:00
parent aef1325ce9
commit 17ca59abe0
7 changed files with 112 additions and 54 deletions

16
src/sys.rs Normal file
View File

@@ -0,0 +1,16 @@
#[link(name = "syscalls")]
extern "C" {
pub fn start_window_draw();
pub fn end_window_draw();
#[link_name = "exit0"]
pub fn exit() -> !;
pub fn define_window(ebx: u32, ecx: u32, edx: u32, edi: u32);
pub fn display_message(ebx: u32, ecx: u32, edx: u32, edi: u32, esi: u32);
pub fn wait_event() -> u32;
pub fn pressed_key() -> u32;
}