1 use super::cargo_handler::{CargoHandler, TargetArch}; 2 setup()3pub fn setup() { 4 let arch = CargoHandler::target_arch(); 5 match arch { 6 TargetArch::Riscv64 => { 7 // CargoHandler::emit_link_arg("-Tsrc/arch/riscv64/link.ld"); 8 CargoHandler::emit_link_arg("-Tsrc/arch/riscv64/link.ld"); 9 CargoHandler::emit_link_arg("--emit-relocs"); 10 CargoHandler::emit_link_arg("--nmagic"); 11 12 CargoHandler::emit_link_arg("--no-relax"); 13 } 14 _ => panic!("Unsupported arch: {:?}", arch), 15 } 16 } 17