Enable use of syntax extensions when cross compiling.

This adds the target triple to the crate metadata.
When searching for a crate the phase (link, syntax) is taken into account.
During link phase only crates matching the target triple are considered.
During syntax phase, either the target or host triple will be accepted, unless
the crate defines a macro_registrar, in which case only the host triple will
match.
This commit is contained in:
Douglas Young 2014-04-17 16:52:25 +01:00
parent 09bfb92fdc
commit 4ac89cd276
28 changed files with 260 additions and 212 deletions

View file

@ -11,7 +11,6 @@
// aux-build:macro_crate_test.rs
// ignore-stage1
// ignore-android
// ignore-cross-compile #12102
#![feature(phase)]

View file

@ -11,7 +11,6 @@
// aux-build:macro_crate_test.rs
// ignore-stage1
// ignore-android
// ignore-cross-compile #12102
#![feature(phase)]

View file

@ -10,7 +10,6 @@
// ignore-stage1
// ignore-pretty
// ignore-cross-compile #12102
#![feature(phase)]

View file

@ -10,7 +10,6 @@
// ignore-stage1
// ignore-pretty
// ignore-cross-compile #12102
#![feature(phase)]

View file

@ -10,7 +10,6 @@
// ignore-stage1
// ignore-pretty
// ignore-cross-compile #12102
#![feature(phase)]

View file

@ -10,7 +10,6 @@
// ignore-stage1
// ignore-pretty
// ignore-cross-compile #12102
#![feature(phase)]

View file

@ -10,7 +10,6 @@
// ignore-stage1
// ignore-pretty
// ignore-cross-compile #12102
#![feature(phase)]

View file

@ -10,7 +10,6 @@
// ignore-stage1
// ignore-pretty
// ignore-cross-compile #12102
#![feature(phase)]

View file

@ -10,7 +10,6 @@
// ignore-stage1
// ignore-pretty
// ignore-cross-compile #12102
#![feature(phase)]

View file

@ -12,8 +12,6 @@
// aux-build:issue-13560-2.rs
// aux-build:issue-13560-3.rs
// ignore-stage1
// ignore-android
// ignore-cross-compile #12102
// Regression test for issue #13560, the test itself is all in the dependent
// libraries. The fail which previously failed to compile is the one numbered 3.

View file

@ -10,8 +10,6 @@
// aux-build:macro_crate_outlive_expansion_phase.rs
// ignore-stage1
// ignore-android
// ignore-cross-compile #12102
#![feature(phase)]

View file

@ -10,8 +10,6 @@
// aux-build:macro_crate_test.rs
// ignore-stage1
// ignore-android
// ignore-cross-compile #12102
#![feature(phase)]

View file

@ -10,17 +10,10 @@
// aux-build:macro_crate_test.rs
// ignore-stage1
// ignore-android
// force-host
// You'll note that there's lots of directives above. This is a very particular
// test in which we're both linking to a macro crate and loading macros from it.
// This implies that both versions are the host architecture, meaning this test
// must also be compiled with the host arch.
// ignore-cross-compile
//
// because this doesn't work with that test runner, ignore-android because it
// can't run host binaries, and force-host to make this test build as the host
// arch.
// macro_crate_test will not compile on a cross-compiled target because
// libsyntax is not compiled for it.
#![feature(phase)]

View file

@ -10,7 +10,6 @@
// ignore-stage1
// ignore-pretty
// ignore-cross-compile
#![feature(phase)]

View file

@ -10,7 +10,6 @@
// ignore-stage1
// ignore-pretty
// ignore-cross-compile #12102
#![feature(phase)]
#[phase(syntax)]