Use entry_point macro in lib.rs too

This commit is contained in:
Philipp Oppermann
2019-04-26 12:00:51 +02:00
parent 2e531850b8
commit c8821cb226

View File

@@ -57,10 +57,15 @@ pub fn hlt_loop() -> ! {
}
}
#[cfg(test)]
use bootloader::{entry_point, BootInfo};
#[cfg(test)]
entry_point!(test_kernel_main);
/// Entry point for `cargo xtest`
#[cfg(test)]
#[no_mangle]
pub extern "C" fn _start() -> ! {
fn test_kernel_main(_boot_info: &'static BootInfo) -> ! {
init();
test_main();
hlt_loop();