about summary refs log tree commit diff
diff options
context:
space:
mode:
authorkennytm <kennytm@gmail.com>2017-12-02 01:38:53 +0800
committerGitHub <noreply@github.com>2017-12-02 01:38:53 +0800
commit263eb4d7ef221e075102c76d85bd7b0d874457b2 (patch)
tree8b15be5f94205e878f47675f56b82fbf910a0d33
parent95f465d5355f559e9c1955a7e4774dc3e619ed63 (diff)
parent94d02b896c3feb5e997b95a660e850c7ad8cbe74 (diff)
downloadrust-263eb4d7ef221e075102c76d85bd7b0d874457b2.tar.gz
rust-263eb4d7ef221e075102c76d85bd7b0d874457b2.zip
Rollup merge of #46280 - tamird:remove-old-refs, r=alexcrichton
rustc_llvm: remove stale references

...that were removed in 77c3bfa7429abf87b76ba84108df018d9e9d90e2.

r? @alexcrichton
-rw-r--r--.gitignore1
-rw-r--r--src/bootstrap/native.rs2
-rw-r--r--src/liballoc_jemalloc/build.rs2
-rw-r--r--src/libprofiler_builtins/build.rs2
-rw-r--r--src/librustc_llvm/build.rs8
-rw-r--r--src/librustc_llvm/ffi.rs18
-rw-r--r--src/librustdoc/build.rs2
7 files changed, 15 insertions, 20 deletions
diff --git a/.gitignore b/.gitignore
index 309fbd95345..57407a2399a 100644
--- a/.gitignore
+++ b/.gitignore
@@ -95,7 +95,6 @@ config.stamp
 keywords.md
 lexer.ml
 src/etc/dl
-src/librustc_llvm/llvmdeps.rs
 tmp.*.rs
 version.md
 version.ml
diff --git a/src/bootstrap/native.rs b/src/bootstrap/native.rs
index ac068ebe651..a5408ee381b 100644
--- a/src/bootstrap/native.rs
+++ b/src/bootstrap/native.rs
@@ -316,7 +316,7 @@ impl Step for TestHelpers {
            .warnings(false)
            .debug(false)
            .file(build.src.join("src/rt/rust_test_helpers.c"))
-           .compile("librust_test_helpers.a");
+           .compile("rust_test_helpers");
     }
 }
 
diff --git a/src/liballoc_jemalloc/build.rs b/src/liballoc_jemalloc/build.rs
index a41a04d7cd4..de5006ad396 100644
--- a/src/liballoc_jemalloc/build.rs
+++ b/src/liballoc_jemalloc/build.rs
@@ -140,6 +140,6 @@ fn main() {
         cc::Build::new()
             .flag("-fvisibility=hidden")
             .file("pthread_atfork_dummy.c")
-            .compile("libpthread_atfork_dummy.a");
+            .compile("pthread_atfork_dummy");
     }
 }
diff --git a/src/libprofiler_builtins/build.rs b/src/libprofiler_builtins/build.rs
index 8508b2dae2c..dd88dd933f6 100644
--- a/src/libprofiler_builtins/build.rs
+++ b/src/libprofiler_builtins/build.rs
@@ -56,5 +56,5 @@ fn main() {
         cfg.file(Path::new("../libcompiler_builtins/compiler-rt/lib/profile").join(src));
     }
 
-    cfg.compile("libprofiler-rt.a");
+    cfg.compile("profiler-rt");
 }
diff --git a/src/librustc_llvm/build.rs b/src/librustc_llvm/build.rs
index 141a9a8d704..f294ceb3f38 100644
--- a/src/librustc_llvm/build.rs
+++ b/src/librustc_llvm/build.rs
@@ -154,13 +154,13 @@ fn main() {
     }
 
     for component in &components {
-        let mut flag = String::from("-DLLVM_COMPONENT_");
+        let mut flag = String::from("LLVM_COMPONENT_");
         flag.push_str(&component.to_uppercase());
-        cfg.flag(&flag);
+        cfg.define(&flag, None);
     }
 
     if env::var_os("LLVM_RUSTLLVM").is_some() {
-        cfg.flag("-DLLVM_RUSTLLVM");
+        cfg.define("LLVM_RUSTLLVM", None);
     }
 
     build_helper::rerun_if_changed_anything_in_dir(Path::new("../rustllvm"));
@@ -169,7 +169,7 @@ fn main() {
        .file("../rustllvm/ArchiveWrapper.cpp")
        .cpp(true)
        .cpp_link_stdlib(None) // we handle this below
-       .compile("librustllvm.a");
+       .compile("rustllvm");
 
     let (llvm_kind, llvm_link_arg) = detect_llvm_link(major, minor, &llvm_config);
 
diff --git a/src/librustc_llvm/ffi.rs b/src/librustc_llvm/ffi.rs
index dd64d76bc0c..1c2fa1bbb48 100644
--- a/src/librustc_llvm/ffi.rs
+++ b/src/librustc_llvm/ffi.rs
@@ -505,17 +505,13 @@ pub mod debuginfo {
 
 pub enum ModuleBuffer {}
 
-// Link to our native llvm bindings (things that we need to use the C++ api
-// for) and because llvm is written in C++ we need to link against libstdc++
-//
-// You'll probably notice that there is an omission of all LLVM libraries
-// from this location. This is because the set of LLVM libraries that we
-// link to is mostly defined by LLVM, and the `llvm-config` tool is used to
-// figure out the exact set of libraries. To do this, the build system
-// generates an llvmdeps.rs file next to this one which will be
-// automatically updated whenever LLVM is updated to include an up-to-date
-// set of the libraries we need to link to LLVM for.
-#[link(name = "rustllvm", kind = "static")] // not quite true but good enough
+// This annotation is primarily needed for MSVC where attributes like
+// dllimport/dllexport are applied and need to be correct for everything to
+// link successfully. The #[link] annotation here says "these symbols are
+// included statically" which means that they're all exported with dllexport
+// and from the rustc_llvm dynamic library. Otherwise the rustc_trans dynamic
+// library would not be able to access these symbols.
+#[link(name = "rustllvm", kind = "static")]
 extern "C" {
     // Create and destroy contexts.
     pub fn LLVMContextCreate() -> ContextRef;
diff --git a/src/librustdoc/build.rs b/src/librustdoc/build.rs
index 97c9ca1e2d2..276825bd31a 100644
--- a/src/librustdoc/build.rs
+++ b/src/librustdoc/build.rs
@@ -27,6 +27,6 @@ fn main() {
        .warnings(false)
        .include(src_dir)
        .warnings(false)
-       .compile("libhoedown.a");
+       .compile("hoedown");
 }