Add syscall library, make init program Rust

This commit is contained in:
Jeremy Soller
2016-09-08 19:09:58 -06:00
parent 44e57773a3
commit ef9a7c0988

4
lib.rs
View File

@@ -135,14 +135,14 @@ pub extern fn kmain() {
let stdin = syscall::open("debug:".as_bytes(), 0);
println!("STDIN: {:?}", stdin);
let stdout = syscall::open("debug:".as_bytes(), 0);
println!("STDOUT: {:?}", stdout);
let stderr = syscall::open("debug:".as_bytes(), 0);
println!("STDERR: {:?}", stderr);
let elf = elf::Elf::from(include_bytes!("../init/main")).expect("could not load elf");
let elf = elf::Elf::from(include_bytes!("../build/init")).expect("could not load elf");
elf.run();
/*