mirror of
https://github.com/rust-lang/rust.git
synced 2024-10-30 05:51:58 +00:00
rustc_back: move dynamic_lib to rustc_metadata.
This commit is contained in:
parent
d6f70359dc
commit
dda924ab6a
1
src/Cargo.lock
generated
1
src/Cargo.lock
generated
@ -1889,7 +1889,6 @@ name = "rustc_plugin"
|
||||
version = "0.0.0"
|
||||
dependencies = [
|
||||
"rustc 0.0.0",
|
||||
"rustc_back 0.0.0",
|
||||
"rustc_errors 0.0.0",
|
||||
"rustc_metadata 0.0.0",
|
||||
"syntax 0.0.0",
|
||||
|
@ -28,10 +28,8 @@
|
||||
|
||||
#![feature(box_syntax)]
|
||||
#![feature(const_fn)]
|
||||
#![feature(libc)]
|
||||
|
||||
extern crate syntax;
|
||||
extern crate libc;
|
||||
extern crate rand;
|
||||
extern crate serialize;
|
||||
#[macro_use] extern crate log;
|
||||
@ -40,7 +38,6 @@ extern crate serialize as rustc_serialize; // used by deriving
|
||||
|
||||
pub mod tempdir;
|
||||
pub mod target;
|
||||
pub mod dynamic_lib;
|
||||
|
||||
use std::str::FromStr;
|
||||
|
||||
|
@ -556,7 +556,7 @@ impl<'a> CrateLoader<'a> {
|
||||
use std::{env, mem};
|
||||
use proc_macro::TokenStream;
|
||||
use proc_macro::__internal::Registry;
|
||||
use rustc_back::dynamic_lib::DynamicLibrary;
|
||||
use dynamic_lib::DynamicLibrary;
|
||||
use syntax_ext::deriving::custom::ProcMacroDerive;
|
||||
use syntax_ext::proc_macro_impl::{AttrProcMacro, BangProcMacro};
|
||||
|
||||
|
@ -16,12 +16,14 @@
|
||||
#![feature(box_patterns)]
|
||||
#![feature(conservative_impl_trait)]
|
||||
#![feature(i128_type)]
|
||||
#![feature(libc)]
|
||||
#![feature(proc_macro_internals)]
|
||||
#![feature(quote)]
|
||||
#![feature(rustc_diagnostic_macros)]
|
||||
#![feature(specialization)]
|
||||
#![feature(rustc_private)]
|
||||
|
||||
extern crate libc;
|
||||
#[macro_use]
|
||||
extern crate log;
|
||||
#[macro_use]
|
||||
@ -54,6 +56,7 @@ mod link_args;
|
||||
|
||||
pub mod creader;
|
||||
pub mod cstore;
|
||||
pub mod dynamic_lib;
|
||||
pub mod locator;
|
||||
|
||||
__build_diagnostic_array! { librustc_metadata, DIAGNOSTICS }
|
||||
|
@ -11,7 +11,6 @@ crate-type = ["dylib"]
|
||||
|
||||
[dependencies]
|
||||
rustc = { path = "../librustc" }
|
||||
rustc_back = { path = "../librustc_back" }
|
||||
rustc_metadata = { path = "../librustc_metadata" }
|
||||
syntax = { path = "../libsyntax" }
|
||||
syntax_pos = { path = "../libsyntax_pos" }
|
||||
|
@ -71,7 +71,6 @@
|
||||
#[macro_use] extern crate syntax;
|
||||
|
||||
extern crate rustc;
|
||||
extern crate rustc_back;
|
||||
extern crate rustc_metadata;
|
||||
extern crate syntax_pos;
|
||||
extern crate rustc_errors as errors;
|
||||
|
@ -115,7 +115,7 @@ impl<'a> PluginLoader<'a> {
|
||||
span: Span,
|
||||
path: PathBuf,
|
||||
symbol: String) -> PluginRegistrarFun {
|
||||
use rustc_back::dynamic_lib::DynamicLibrary;
|
||||
use rustc_metadata::dynamic_lib::DynamicLibrary;
|
||||
|
||||
// Make sure the path contains a / or the linker will search for it.
|
||||
let path = env::current_dir().unwrap().join(&path);
|
||||
|
@ -16,7 +16,7 @@ use std::mem;
|
||||
use std::string::String;
|
||||
use std::path::PathBuf;
|
||||
|
||||
use rustc_back::dynamic_lib as dl;
|
||||
use rustc_metadata::dynamic_lib as dl;
|
||||
|
||||
pub type PluginResult = clean::Crate;
|
||||
pub type PluginCallback = fn (clean::Crate) -> PluginResult;
|
||||
|
@ -27,7 +27,7 @@ use rustc::hir::intravisit;
|
||||
use rustc::session::{self, CompileIncomplete, config};
|
||||
use rustc::session::config::{OutputType, OutputTypes, Externs};
|
||||
use rustc::session::search_paths::{SearchPaths, PathKind};
|
||||
use rustc_back::dynamic_lib::DynamicLibrary;
|
||||
use rustc_metadata::dynamic_lib::DynamicLibrary;
|
||||
use rustc_back::tempdir::TempDir;
|
||||
use rustc_driver::{self, driver, Compilation};
|
||||
use rustc_driver::driver::phase_2_configure_and_expand;
|
||||
|
@ -10,9 +10,9 @@
|
||||
|
||||
#![feature(rustc_private)]
|
||||
|
||||
extern crate rustc_back;
|
||||
extern crate rustc_metadata;
|
||||
|
||||
use rustc_back::dynamic_lib::DynamicLibrary;
|
||||
use rustc_metadata::dynamic_lib::DynamicLibrary;
|
||||
use std::path::Path;
|
||||
|
||||
pub fn main() {
|
||||
|
@ -14,9 +14,9 @@
|
||||
// do the runtime check that these functions aren't exported.
|
||||
#![allow(private_no_mangle_fns)]
|
||||
|
||||
extern crate rustc_back;
|
||||
extern crate rustc_metadata;
|
||||
|
||||
use rustc_back::dynamic_lib::DynamicLibrary;
|
||||
use rustc_metadata::dynamic_lib::DynamicLibrary;
|
||||
|
||||
#[no_mangle]
|
||||
pub fn foo() { bar(); }
|
||||
|
Loading…
Reference in New Issue
Block a user