about summary refs log tree commit diff
path: root/src/libstd/sys_common
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2016-12-15 06:23:11 +0000
committerbors <bors@rust-lang.org>2016-12-15 06:23:11 +0000
commitcfa668f3bf8156730b419deec51fb980af23b8bb (patch)
tree00f70114d72e3d944ac12d973ad6db58e91e3770 /src/libstd/sys_common
parent7ad7232422f7e5bbfa0e52dabe36c12677df19e2 (diff)
parent3e15dc108c66891da04aa8c3f77162746fab4277 (diff)
downloadrust-cfa668f3bf8156730b419deec51fb980af23b8bb.tar.gz
rust-cfa668f3bf8156730b419deec51fb980af23b8bb.zip
Auto merge of #37702 - redox-os:redox, r=brson
Redox Support Preview

# Important - This is only a preview of a working `sys::redox`.

Compiling the Redox default distribution with this `libstd` results in a fully functioning distribution. As such, all further changes would be cosmetic or implementing features that have not been used by the default distribution (of which there are only a small number).

I do not expect this to be merged, but would like to discuss how it may be improved and get feedback.

There are a few `unimplemented!()` - `cloexec` for example. I have documented them below. These would be resolved before desiring a merge.

There are also issues with how the Redox syscall library is called - currently I am using a re-export in `libc` but that probably would not be desired.
Diffstat (limited to 'src/libstd/sys_common')
-rw-r--r--src/libstd/sys_common/mod.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/libstd/sys_common/mod.rs b/src/libstd/sys_common/mod.rs
index fe17d8cb5e5..5c07e36508c 100644
--- a/src/libstd/sys_common/mod.rs
+++ b/src/libstd/sys_common/mod.rs
@@ -34,7 +34,6 @@ pub mod condvar;
 pub mod io;
 pub mod memchr;
 pub mod mutex;
-pub mod net;
 pub mod poison;
 pub mod remutex;
 pub mod rwlock;
@@ -44,6 +43,12 @@ pub mod thread_local;
 pub mod util;
 pub mod wtf8;
 
+#[cfg(target_os = "redox")]
+pub use sys::net;
+
+#[cfg(not(target_os = "redox"))]
+pub mod net;
+
 #[cfg(any(not(cargobuild), feature = "backtrace"))]
 #[cfg(any(all(unix, not(any(target_os = "macos", target_os = "ios", target_os = "emscripten"))),
           all(windows, target_env = "gnu")))]