[arch-commits] Commit in rust/trunk (3 files)

Jan Steffens heftig at archlinux.org
Wed Nov 20 13:12:45 UTC 2019


    Date: Wednesday, November 20, 2019 @ 13:12:44
  Author: heftig
Revision: 369480

Add a patch fixing the build

Added:
  rust/trunk/0002-Hopefully-fix-rustdoc-build.patch
Modified:
  rust/trunk/0001-WIP-minimize-the-rust-std-component.patch
  rust/trunk/PKGBUILD

------------------------------------------------+
 0001-WIP-minimize-the-rust-std-component.patch |    4 +-
 0002-Hopefully-fix-rustdoc-build.patch         |   38 +++++++++++++++++++++++
 PKGBUILD                                       |   10 ++++--
 3 files changed, 48 insertions(+), 4 deletions(-)

Modified: 0001-WIP-minimize-the-rust-std-component.patch
===================================================================
--- 0001-WIP-minimize-the-rust-std-component.patch	2019-11-20 13:12:08 UTC (rev 369479)
+++ 0001-WIP-minimize-the-rust-std-component.patch	2019-11-20 13:12:44 UTC (rev 369480)
@@ -1,7 +1,7 @@
-From 14948e9d7bdb5cc7e975c1f3435692eeb748f07b Mon Sep 17 00:00:00 2001
+From e36ab8edbda3695abf3bf892c0fcb17a1f306302 Mon Sep 17 00:00:00 2001
 From: Josh Stone <jistone at redhat.com>
 Date: Fri, 27 Sep 2019 12:33:08 -0700
-Subject: [PATCH] [WIP] minimize the rust-std component
+Subject: [PATCH 1/2] [WIP] minimize the rust-std component
 
 ---
  src/bootstrap/dist.rs | 33 +++++++++------------------------

Added: 0002-Hopefully-fix-rustdoc-build.patch
===================================================================
--- 0002-Hopefully-fix-rustdoc-build.patch	                        (rev 0)
+++ 0002-Hopefully-fix-rustdoc-build.patch	2019-11-20 13:12:44 UTC (rev 369480)
@@ -0,0 +1,38 @@
+From 3e846aeb807bfc41576b4efbee882c4475f0cb75 Mon Sep 17 00:00:00 2001
+From: Mark Rousskov <mark.simulacrum at gmail.com>
+Date: Tue, 5 Nov 2019 11:16:46 -0500
+Subject: [PATCH 2/2] Hopefully fix rustdoc build
+
+It's super unclear why this broke when we switched to beta but not
+previously -- but at least it's hopefully fixed now.
+---
+ src/bootstrap/builder.rs | 13 ++++++++++++-
+ 1 file changed, 12 insertions(+), 1 deletion(-)
+
+diff --git a/src/bootstrap/builder.rs b/src/bootstrap/builder.rs
+index 5d586f0c461..bad92d77385 100644
+--- a/src/bootstrap/builder.rs
++++ b/src/bootstrap/builder.rs
+@@ -875,7 +875,18 @@ impl<'a> Builder<'a> {
+         // things still build right, please do!
+         match mode {
+             Mode::Std => metadata.push_str("std"),
+-            _ => {},
++            // When we're building rustc tools, they're built with a search path
++            // that contains things built during the rustc build. For example,
++            // bitflags is built during the rustc build, and is a dependency of
++            // rustdoc as well. We're building rustdoc in a different target
++            // directory, though, which means that Cargo will rebuild the
++            // dependency. When we go on to build rustdoc, we'll look for
++            // bitflags, and find two different copies: one built during the
++            // rustc step and one that we just built. This isn't always a
++            // problem, somehow -- not really clear why -- but we know that this
++            // fixes things.
++            Mode::ToolRustc => metadata.push_str("tool-rustc"),
++            _ => {}
+         }
+         cargo.env("__CARGO_DEFAULT_LIB_METADATA", &metadata);
+ 
+-- 
+2.24.0
+

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2019-11-20 13:12:08 UTC (rev 369479)
+++ PKGBUILD	2019-11-20 13:12:44 UTC (rev 369480)
@@ -22,13 +22,15 @@
 
 source=("https://static.rust-lang.org/dist/rustc-$pkgver-src.tar.gz"{,.asc}
         "http://releases.llvm.org/$_llvm_ver/compiler-rt-$_llvm_ver.src.tar.xz"{,.sig}
-        0001-WIP-minimize-the-rust-std-component.patch)
+        0001-WIP-minimize-the-rust-std-component.patch
+        0002-Hopefully-fix-rustdoc-build.patch)
 
 sha256sums=('b4a1f6b6a93931f270691aba4fc85eee032fecda973e6b9c774cd06857609357'
             'SKIP'
             '56e4cd96dd1d8c346b07b4d6b255f976570c6f2389697347a6c3dcb9e820d10e'
             'SKIP'
-            '9e64e6abe9b118ee496c317ef37f4b500b54ecd69e9c02cad2a6a0b7235e9afd')
+            'a7e525eb4d937f569ff126db0c08ca8098d0d8fe6c26132992d2ac108885dbf3'
+            'c376f987d55c65254522ce267956f68999d62bb86e3401e19ae0a092c943a7c3')
 validpgpkeys=('108F66205EAEB0AAA8DD5E1C85AB96E6FA1BE5FE'  # Rust Language (Tag and Release Signing Key) <rust-key at rust-lang.org>
               '474E22316ABF4785A88C6E8EA2C794A986419D8A'  # Tom Stellard <tstellar at redhat.com>
               'B6C8F98282B944E3B0D5C2530FC3042E345AD05D') # Hans Wennborg <hans at chromium.org>
@@ -40,6 +42,10 @@
   # From https://src.fedoraproject.org/rpms/rust/tree/master
   patch -Np1 -i ../0001-WIP-minimize-the-rust-std-component.patch
 
+  # For https://bugs.archlinux.org/task/64550
+  # From https://github.com/rust-lang/rust/issues/65795#issuecomment-551766737
+  patch -Np1 -i ../0002-Hopefully-fix-rustdoc-build.patch
+
   cat >config.toml <<END
 [llvm]
 link-shared = true



More information about the arch-commits mailing list