diff --git a/Cargo.toml b/Cargo.toml index a478254..9a0f736 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -3,4 +3,10 @@ name = "simpleos" version = "0.1.0" edition = "2021" +[profile.dev] +panic = "abort" + +[profile.release] +panic = "abort" + [dependencies] diff --git a/src/main.rs b/src/main.rs index e7a11a9..716751a 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,3 +1,14 @@ -fn main() { - println!("Hello, world!"); +#![no_std] +#![no_main] + +use core::panic::PanicInfo; + +#[no_mangle] +pub extern "C" fn _start() -> ! { + loop {} +} + +#[panic_handler] +fn panic(_info: &PanicInfo) -> ! { + loop {} }