From ea21fba3aa90458531d7a2329b94defb5cd608d6 Mon Sep 17 00:00:00 2001 From: Robin Randhawa Date: Fri, 15 Jan 2021 12:25:42 +0000 Subject: [PATCH] build.rs: aarch64: Specify target for cc::Build Oddly, not specifying this or using aarch64-unknown-none (which would be the default that cc gets from the TARGET environment variable) both fail to invoke the appropriate compiler to build the asm code. Using aarch64-unknown-redox works but shouldn't really be needed. This is perhaps because of some odd arrangement of KTARGET, TARGET, the installed prefix toolchain and the kernel target JSON spec. The early_init asm code shall be replaced by a pure Rust bootloader eventually so let's move with this for the moment. --- build.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/build.rs b/build.rs index 8ca068f..249c9e3 100644 --- a/build.rs +++ b/build.rs @@ -166,6 +166,7 @@ mod gen { println!("cargo:rerun-if-changed=src/arch/aarch64/init/pre_kstart/early_init.S"); cc::Build::new() .file("src/arch/aarch64/init/pre_kstart/early_init.S") + .target("aarch64-unknown-redox") .compile("early_init"); } }