From ef4a4f3282f4da34be831674f427a6fa1bc27155 Mon Sep 17 00:00:00 2001 From: Hiroki Tokunaga Date: Tue, 29 Jun 2021 23:12:37 +0900 Subject: [PATCH] chore(init): specify a target explicitly To avoid to compile `build.rs` wrongly. Without this it will be compiled with `kernel.ld` as specified in `.cargo/config.toml`. See https://github.com/rust-lang/cargo/issues/6375#issuecomment-444900324. --- kernel/.cargo/config.toml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kernel/.cargo/config.toml b/kernel/.cargo/config.toml index f6f8e89e..0b454e1b 100644 --- a/kernel/.cargo/config.toml +++ b/kernel/.cargo/config.toml @@ -1,4 +1,7 @@ [build] +target = "x86_64-unknown-linux-gnu" + +[target.x86_64-unknown-linux-gnu] rustflags = [ "-C", "code-model=kernel", "-C", "link-args=-T kernel/kernel.ld",