summaryrefslogtreecommitdiff
path: root/lang/rust/files/powerpc64-elfv1/patch-src_librustc__llvm_build.rs
diff options
context:
space:
mode:
Diffstat (limited to 'lang/rust/files/powerpc64-elfv1/patch-src_librustc__llvm_build.rs')
-rw-r--r--lang/rust/files/powerpc64-elfv1/patch-src_librustc__llvm_build.rs14
1 files changed, 14 insertions, 0 deletions
diff --git a/lang/rust/files/powerpc64-elfv1/patch-src_librustc__llvm_build.rs b/lang/rust/files/powerpc64-elfv1/patch-src_librustc__llvm_build.rs
new file mode 100644
index 000000000000..db32de43d8c5
--- /dev/null
+++ b/lang/rust/files/powerpc64-elfv1/patch-src_librustc__llvm_build.rs
@@ -0,0 +1,14 @@
+--- src/librustc_llvm/build.rs.orig 2019-11-04 15:45:21 UTC
++++ src/librustc_llvm/build.rs
+@@ -273,7 +273,10 @@ fn main() {
+ };
+
+ // C++ runtime library
+- if !target.contains("msvc") {
++ if target == "powerpc64-unknown-freebsd" {
++ println!("cargo:rustc-link-search=native=/usr/local/lib/%CC%");
++ println!("cargo:rustc-link-lib=static=stdc++");
++ } else if !target.contains("msvc") {
+ if let Some(s) = llvm_static_stdcpp {
+ assert!(!cxxflags.contains("stdlib=libc++"));
+ let path = PathBuf::from(s);