about summary refs log tree commit diff
path: root/src/librustrt
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2014-06-09 15:52:07 -0700
committerbors <bors@rust-lang.org>2014-06-09 15:52:07 -0700
commit0ea7aa30cc864d00fc30b9ba610f2daefab4e850 (patch)
tree2f3216efe5cc25851595c14d803dc69738030a72 /src/librustrt
parentb6146e652ae7f6d373d55dd021dc50cb00e0caf8 (diff)
parentdeecda6a94b31489045d420f16840a72c44af7e1 (diff)
downloadrust-0ea7aa30cc864d00fc30b9ba610f2daefab4e850.tar.gz
rust-0ea7aa30cc864d00fc30b9ba610f2daefab4e850.zip
auto merge of #14554 : kmcallister/rust/plugin_registrar, r=cmr
This implements the design in rust-lang/rfcs#86.  It shouldn't be merged until that RFC is accepted, but it would be great if somebody has time to review the code before then.
Diffstat (limited to 'src/librustrt')
-rw-r--r--src/librustrt/lib.rs10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/librustrt/lib.rs b/src/librustrt/lib.rs
index 3158687c6ab..bb57f5c038c 100644
--- a/src/librustrt/lib.rs
+++ b/src/librustrt/lib.rs
@@ -19,8 +19,14 @@
 #![no_std]
 #![experimental]
 
+#[cfg(stage0)]
 #[phase(syntax, link)]
 extern crate core;
+
+#[cfg(not(stage0))]
+#[phase(plugin, link)]
+extern crate core;
+
 extern crate alloc;
 extern crate libc;
 extern crate collections;
@@ -28,7 +34,9 @@ extern crate collections;
 #[cfg(test)] extern crate realrustrt = "rustrt";
 #[cfg(test)] extern crate test;
 #[cfg(test)] extern crate native;
-#[cfg(test)] #[phase(syntax, link)] extern crate std;
+
+#[cfg(test, stage0)] #[phase(syntax, link)] extern crate std;
+#[cfg(test, not(stage0))] #[phase(plugin, link)] extern crate std;
 
 pub use self::util::{Stdio, Stdout, Stderr};
 pub use self::unwind::{begin_unwind, begin_unwind_fmt};