Add x86_64-unknown-linux-none target

This commit is contained in:
Federico Maria Morrone 2024-03-24 15:33:00 +01:00
parent 3349155ac0
commit a3ef01b1fc
No known key found for this signature in database
GPG Key ID: C38721DBA7B7F093
2 changed files with 28 additions and 0 deletions

View File

@ -1774,6 +1774,9 @@ supported_targets! {
("aarch64-unknown-linux-ohos", aarch64_unknown_linux_ohos), ("aarch64-unknown-linux-ohos", aarch64_unknown_linux_ohos),
("armv7-unknown-linux-ohos", armv7_unknown_linux_ohos), ("armv7-unknown-linux-ohos", armv7_unknown_linux_ohos),
("x86_64-unknown-linux-ohos", x86_64_unknown_linux_ohos), ("x86_64-unknown-linux-ohos", x86_64_unknown_linux_ohos),
("x86_64-unknown-linux-none", x86_64_unknown_linux_none),
} }
/// Cow-Vec-Str: Cow<'static, [Cow<'static, str>]> /// Cow-Vec-Str: Cow<'static, [Cow<'static, str>]>

View File

@ -0,0 +1,25 @@
use crate::spec::{base, Cc, LinkerFlavor, Lld, StackProbeType, Target};
pub fn target() -> Target {
let mut base = base::linux::opts();
base.cpu = "x86-64".into();
base.max_atomic_width = Some(64);
base.stack_probes = StackProbeType::Inline;
base.linker_flavor = LinkerFlavor::Gnu(Cc::No, Lld::Yes);
base.linker = Some("rust-lld".into());
Target {
llvm_target: "x86_64-unknown-linux-none".into(),
metadata: crate::spec::TargetMetadata {
description: None,
tier: None,
host_tools: None,
std: None,
},
pointer_width: 64,
data_layout:
"e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128".into(),
arch: "x86_64".into(),
options: base,
}
}