forked from M-Labs/artiq
board_misoc: reuse riscv dir for comm & kernel
This commit is contained in:
parent
cb247f235f
commit
0898e101e2
|
@ -1,19 +1,16 @@
|
|||
extern crate build_misoc;
|
||||
extern crate cc;
|
||||
|
||||
use std::env;
|
||||
use std::path::Path;
|
||||
|
||||
fn main() {
|
||||
build_misoc::cfg();
|
||||
|
||||
let triple = env::var("TARGET").unwrap();
|
||||
let arch = triple.split("-").next().unwrap();
|
||||
let vectors_path = Path::new(arch).join("vectors.S");
|
||||
let vectors_path = "riscv32/vectors.S";
|
||||
|
||||
println!("cargo:rerun-if-changed={}", vectors_path.to_str().unwrap());
|
||||
println!("cargo:rerun-if-changed={}", vectors_path);
|
||||
cc::Build::new()
|
||||
.flag("--target=riscv32-unknown-elf")
|
||||
.file(vectors_path)
|
||||
.file(Path::new(vectors_path))
|
||||
.compile("vectors");
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@ extern crate log;
|
|||
extern crate smoltcp;
|
||||
|
||||
#[cfg(target_arch = "riscv32")]
|
||||
#[path = "riscv32ima/mod.rs"]
|
||||
#[path = "riscv32/mod.rs"]
|
||||
mod arch;
|
||||
|
||||
#[cfg(target_arch = "riscv32")]
|
||||
|
|
Loading…
Reference in New Issue