Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions src/doc/unstable-book/src/library-features/n16.md

This file was deleted.

3 changes: 1 addition & 2 deletions src/libpanic_abort/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,7 @@ pub unsafe extern fn __rust_start_panic(_payload: usize) -> u32 {
libc::abort();
}

#[cfg(any(target_os = "redox",
windows,
#[cfg(any(windows,
all(target_arch = "wasm32", not(target_os = "emscripten"))))]
unsafe fn abort() -> ! {
core::intrinsics::abort();
Expand Down
20 changes: 20 additions & 0 deletions src/librustc_target/spec/aarch64_unknown_redox.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
use crate::spec::{LinkerFlavor, Target, TargetResult};

pub fn target() -> TargetResult {
let mut base = super::redox_base::opts();
base.max_atomic_width = Some(128);

Ok(Target {
llvm_target: "aarch64-unknown-redox".to_string(),
target_endian: "little".to_string(),
target_pointer_width: "64".to_string(),
target_c_int_width: "32".to_string(),
data_layout: "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128".to_string(),
arch: "aarch64".to_string(),
target_os: "redox".to_string(),
target_env: "relibc".to_string(),
target_vendor: "unknown".to_string(),
linker_flavor: LinkerFlavor::Gcc,
options: base,
})
}
1 change: 1 addition & 0 deletions src/librustc_target/spec/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -417,6 +417,7 @@ supported_targets! {

("x86_64-unknown-l4re-uclibc", x86_64_unknown_l4re_uclibc),

("aarch64-unknown-redox", aarch64_unknown_redox),
("x86_64-unknown-redox", x86_64_unknown_redox),

("i386-apple-ios", i386_apple_ios),
Expand Down
15 changes: 9 additions & 6 deletions src/librustc_target/spec/redox_base.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::spec::{LinkArgs, LinkerFlavor, TargetOptions};
use crate::spec::{LinkArgs, LinkerFlavor, TargetOptions, RelroLevel};
use std::default::Default;

pub fn opts() -> TargetOptions {
Expand All @@ -18,14 +18,17 @@ pub fn opts() -> TargetOptions {
]);

TargetOptions {
pre_link_args: args,
dynamic_linking: true,
executables: true,
relocation_model: "static".to_string(),
disable_redzone: true,
eliminate_frame_pointer: false,
target_family: None,
target_family: Some("unix".to_string()),
linker_is_gnu: true,
has_rpath: true,
pre_link_args: args,
position_independent_executables: true,
relro_level: RelroLevel::Full,
has_elf_tls: true,
crt_static_default: true,
crt_static_respected: true,
.. Default::default()
}
}
2 changes: 1 addition & 1 deletion src/librustc_target/spec/x86_64_unknown_redox.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ pub fn target() -> TargetResult {
data_layout: "e-m:e-i64:64-f80:128-n8:16:32:64-S128".to_string(),
arch: "x86_64".to_string(),
target_os: "redox".to_string(),
target_env: String::new(),
target_env: "relibc".to_string(),
target_vendor: "unknown".to_string(),
linker_flavor: LinkerFlavor::Gcc,
options: base,
Expand Down
1 change: 1 addition & 0 deletions src/libstd/os/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ cfg_if::cfg_if! {
#[cfg(target_os = "emscripten")] pub mod emscripten;
#[cfg(target_os = "fuchsia")] pub mod fuchsia;
#[cfg(target_os = "hermit")] pub mod hermit;
#[cfg(target_os = "redox")] pub mod redox;
#[cfg(target_os = "wasi")] pub mod wasi;
#[cfg(target_os = "vxworks")] pub mod vxworks;
#[cfg(all(target_vendor = "fortanix", target_env = "sgx"))] pub mod fortanix_sgx;
Expand Down
Loading