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

2019-12-19 Thread Jan Steffens via arch-commits
Date: Friday, December 20, 2019 @ 02:34:51
  Author: heftig
Revision: 371947

1.40.0-1

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

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

Deleted: 0001-WIP-minimize-the-rust-std-component.patch
===
--- 0001-WIP-minimize-the-rust-std-component.patch  2019-12-19 22:58:51 UTC 
(rev 371946)
+++ 0001-WIP-minimize-the-rust-std-component.patch  2019-12-20 02:34:51 UTC 
(rev 371947)
@@ -1,62 +0,0 @@
-From e36ab8edbda3695abf3bf892c0fcb17a1f306302 Mon Sep 17 00:00:00 2001
-From: Josh Stone 
-Date: Fri, 27 Sep 2019 12:33:08 -0700
-Subject: [PATCH 1/2] [WIP] minimize the rust-std component
-

- src/bootstrap/dist.rs | 33 +
- 1 file changed, 9 insertions(+), 24 deletions(-)
-
-diff --git a/src/bootstrap/dist.rs b/src/bootstrap/dist.rs
-index d9dff77a30e..bd96a6371fc 100644
 a/src/bootstrap/dist.rs
-+++ b/src/bootstrap/dist.rs
-@@ -675,36 +675,21 @@ impl Step for Std {
- return distdir(builder).join(format!("{}-{}.tar.gz", name, 
target));
- }
- 
--// We want to package up as many target libraries as possible
--// for the `rust-std` package, so if this is a host target we
--// depend on librustc and otherwise we just depend on libtest.
--if builder.hosts.iter().any(|t| t == target) {
--builder.ensure(compile::Rustc { compiler, target });
--} else {
--builder.ensure(compile::Std { compiler, target });
--}
-+builder.ensure(compile::Std { compiler, target });
- 
- let image = tmpdir(builder).join(format!("{}-{}-image", name, 
target));
- let _ = fs::remove_dir_all();
- 
--let dst = image.join("lib/rustlib").join(target);
-+let dst = image.join("lib/rustlib").join(target).join("lib");
- t!(fs::create_dir_all());
--let mut src = builder.sysroot_libdir(compiler, target).to_path_buf();
--src.pop(); // Remove the trailing /lib folder from the sysroot_libdir
--builder.cp_filtered(, , &|path| {
--if let Some(name) = path.file_name().and_then(|s| s.to_str()) {
--if name == builder.config.rust_codegen_backends_dir.as_str() {
--return false
--}
--if name == "bin" {
--return false
--}
--if name.contains("LLVM") {
--return false
--}
-+
-+let compiler_to_use = builder.compiler_for(compiler.stage, 
compiler.host, target);
-+let stamp = dbg!(compile::libstd_stamp(builder, compiler_to_use, 
target));
-+for (path, host) in builder.read_stamp_file() {
-+if !host {
-+builder.copy(, (path.file_name().unwrap()));
- }
--true
--});
-+}
- 
- let mut cmd = rust_installer(builder);
- cmd.arg("generate")
--- 
-2.24.0
-

Deleted: 0002-Hopefully-fix-rustdoc-build.patch
===
--- 0002-Hopefully-fix-rustdoc-build.patch  2019-12-19 22:58:51 UTC (rev 
371946)
+++ 0002-Hopefully-fix-rustdoc-build.patch  2019-12-20 02:34:51 UTC (rev 
371947)
@@ -1,38 +0,0 @@
-From 3e846aeb807bfc41576b4efbee882c4475f0cb75 Mon Sep 17 00:00:00 2001
-From: Mark Rousskov 
-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 

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

2019-11-20 Thread Jan Steffens via arch-commits
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 
 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 
+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", );
+ 
+-- 
+2.24.0
+

Modified: PKGBUILD
===
--- PKGBUILD2019-11-20 13:12:08 UTC (rev 369479)
+++ PKGBUILD2019-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) 
   '474E22316ABF4785A88C6E8EA2C794A986419D8A'  # Tom Stellard 

   'B6C8F98282B944E3B0D5C2530FC3042E345AD05D') # Hans Wennborg 

@@ -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 <

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

2019-11-07 Thread Jan Steffens via arch-commits
Date: Thursday, November 7, 2019 @ 17:31:20
  Author: heftig
Revision: 367138

1.39.0-1

Modified:
  rust/trunk/0001-WIP-minimize-the-rust-std-component.patch
  rust/trunk/PKGBUILD
Deleted:
  rust/trunk/bootstrap-1.38.patch

+
 0001-WIP-minimize-the-rust-std-component.patch |   26 ++-
 PKGBUILD   |   13 +++
 bootstrap-1.38.patch   |   13 ---
 3 files changed, 11 insertions(+), 41 deletions(-)

Modified: 0001-WIP-minimize-the-rust-std-component.patch
===
--- 0001-WIP-minimize-the-rust-std-component.patch  2019-11-07 16:51:50 UTC 
(rev 367137)
+++ 0001-WIP-minimize-the-rust-std-component.patch  2019-11-07 17:31:20 UTC 
(rev 367138)
@@ -1,17 +1,17 @@
-From 2bf05f208272cd58c57f4d7d8d0e10fdb22e8719 Mon Sep 17 00:00:00 2001
+From 14948e9d7bdb5cc7e975c1f3435692eeb748f07b Mon Sep 17 00:00:00 2001
 From: Josh Stone 
 Date: Fri, 27 Sep 2019 12:33:08 -0700
 Subject: [PATCH] [WIP] minimize the rust-std component
 
 ---
- src/bootstrap/dist.rs | 45 +++
- 1 file changed, 16 insertions(+), 29 deletions(-)
+ src/bootstrap/dist.rs | 33 +
+ 1 file changed, 9 insertions(+), 24 deletions(-)
 
 diff --git a/src/bootstrap/dist.rs b/src/bootstrap/dist.rs
-index 552965863d10..76fbd07f9fb5 100644
+index d9dff77a30e..bd96a6371fc 100644
 --- a/src/bootstrap/dist.rs
 +++ b/src/bootstrap/dist.rs
-@@ -667,41 +667,28 @@ impl Step for Std {
+@@ -675,36 +675,21 @@ impl Step for Std {
  return distdir(builder).join(format!("{}-{}.tar.gz", name, 
target));
  }
  
@@ -21,15 +21,9 @@
 -if builder.hosts.iter().any(|t| t == target) {
 -builder.ensure(compile::Rustc { compiler, target });
 -} else {
--if builder.no_std(target) == Some(true) {
--// the `test` doesn't compile for no-std targets
--builder.ensure(compile::Std { compiler, target });
--} else {
--builder.ensure(compile::Test { compiler, target });
--}
+-builder.ensure(compile::Std { compiler, target });
 -}
 +builder.ensure(compile::Std { compiler, target });
-+builder.ensure(compile::Test { compiler, target });
  
  let image = tmpdir(builder).join(format!("{}-{}-image", name, 
target));
  let _ = fs::remove_dir_all();
@@ -60,15 +54,9 @@
 -true
 -});
 +}
-+let stamp = dbg!(compile::libtest_stamp(builder, compiler_to_use, 
target));
-+for (path, host) in builder.read_stamp_file() {
-+if !host {
-+builder.copy(, (path.file_name().unwrap()));
-+}
-+}
  
  let mut cmd = rust_installer(builder);
  cmd.arg("generate")
 -- 
-2.21.0
+2.24.0
 

Modified: PKGBUILD
===
--- PKGBUILD2019-11-07 16:51:50 UTC (rev 367137)
+++ PKGBUILD2019-11-07 17:31:20 UTC (rev 367138)
@@ -5,8 +5,8 @@
 
 pkgname=('rust' 'lib32-rust-libs' 'rust-docs')
 epoch=1
-pkgver=1.38.0
-pkgrel=2
+pkgver=1.39.0
+pkgrel=1
 
 _llvm_ver=9.0.0
 
@@ -22,15 +22,13 @@
 
 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}
-bootstrap-1.38.patch
 0001-WIP-minimize-the-rust-std-component.patch)
 
-sha256sums=('644263ca7c7106f8ee8fcde6bb16910d246b30668a74be20b8c7e0e9f4a52d80'
+sha256sums=('b4a1f6b6a93931f270691aba4fc85eee032fecda973e6b9c774cd06857609357'
 'SKIP'
 '56e4cd96dd1d8c346b07b4d6b255f976570c6f2389697347a6c3dcb9e820d10e'
 'SKIP'
-'71935e8994d1045680cde22f72a12c4959e1877e5a42fc21fd034d677100dab3'
-'1d6b69444ef6ff033fe1612e56ecdaad5c52aa44395e704f78b1a047c65b9321')
+'9e64e6abe9b118ee496c317ef37f4b500b54ecd69e9c02cad2a6a0b7235e9afd')
 validpgpkeys=('108F66205EAEB0AAA8DD5E1C85AB96E6FA1BE5FE'  # Rust Language (Tag 
and Release Signing Key) 
   '474E22316ABF4785A88C6E8EA2C794A986419D8A'  # Tom Stellard 

   'B6C8F98282B944E3B0D5C2530FC3042E345AD05D') # Hans Wennborg 

@@ -38,9 +36,6 @@
 prepare() {
   cd "rustc-$pkgver-src"
 
-  # Fix bootstrap to compile with 1.38
-  patch -Np1 -i ../bootstrap-1.38.patch
-
   # For https://bugzilla.redhat.com/show_bug.cgi?id=1756487
   # From https://src.fedoraproject.org/rpms/rust/tree/master
   patch -Np1 -i ../0001-WIP-minimize-the-rust-std-component.patch

Deleted: bootstrap-1.38.patch
===
--- bootstrap-1.38.patch2019-11-07 16:51:50 UTC (rev 367137)
+++ bootstrap-1.38.patch2019-11-07 17:31:20 UTC (rev 367138)
@@ -1,13 +0,0 @@
-diff --git 

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

2019-04-12 Thread Johannes Löthberg via arch-commits
Date: Friday, April 12, 2019 @ 21:54:30
  Author: demize
Revision: 350688

upgpkg: rust 1:1.34.0-1

Modified:
  rust/trunk/PKGBUILD
Deleted:
  rust/trunk/0001-Backport-deprecation-fixes-from-commit-b7f030e.patch
  rust/trunk/0001-Revert-1c95f5a34c14f08d65cdd198827e3a2fcb63cf39-9452.patch

-+
 0001-Backport-deprecation-fixes-from-commit-b7f030e.patch   |   57 
--
 0001-Revert-1c95f5a34c14f08d65cdd198827e3a2fcb63cf39-9452.patch |   30 -
 PKGBUILD|   20 +--
 3 files changed, 7 insertions(+), 100 deletions(-)

Deleted: 0001-Backport-deprecation-fixes-from-commit-b7f030e.patch
===
--- 0001-Backport-deprecation-fixes-from-commit-b7f030e.patch   2019-04-12 
19:42:29 UTC (rev 350687)
+++ 0001-Backport-deprecation-fixes-from-commit-b7f030e.patch   2019-04-12 
21:54:30 UTC (rev 350688)
@@ -1,57 +0,0 @@
-From 55030c7543d8e877ec7a6b577a51422c38f01259 Mon Sep 17 00:00:00 2001
-From: Josh Stone 
-Date: Fri, 1 Mar 2019 09:27:45 -0800
-Subject: [PATCH] Backport deprecation fixes from commit b7f030e
-

- src/tools/linkchecker/main.rs  | 6 +++---
- src/tools/tidy/src/features.rs | 2 +-
- 2 files changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/src/tools/linkchecker/main.rs b/src/tools/linkchecker/main.rs
-index 59662be349dc..2cf0fcfd34cd 100644
 a/src/tools/linkchecker/main.rs
-+++ b/src/tools/linkchecker/main.rs
-@@ -78,7 +78,7 @@ impl FileEntry {
- fn parse_ids( self, file: , contents: , errors:  bool) {
- if self.ids.is_empty() {
- with_attrs_in_source(contents, " id", |fragment, i, _| {
--let frag = fragment.trim_left_matches("#").to_owned();
-+let frag = fragment.trim_start_matches("#").to_owned();
- let encoded = small_url_encode();
- if !self.ids.insert(frag) {
- *errors = true;
-@@ -343,7 +343,7 @@ fn with_attrs_in_source(contents: , attr: ,
- Some(i) => i,
- None => continue,
- };
--if rest[..pos_equals].trim_left_matches(" ") != "" {
-+if rest[..pos_equals].trim_start_matches(" ") != "" {
- continue;
- }
- 
-@@ -355,7 +355,7 @@ fn with_attrs_in_source(contents: , attr: ,
- };
- let quote_delim = rest.as_bytes()[pos_quote] as char;
- 
--if rest[..pos_quote].trim_left_matches(" ") != "" {
-+if rest[..pos_quote].trim_start_matches(" ") != "" {
- continue;
- }
- let rest = [pos_quote + 1..];
-diff --git a/src/tools/tidy/src/features.rs b/src/tools/tidy/src/features.rs
-index 2435a0cfd4e3..bf2cfbf32fc7 100644
 a/src/tools/tidy/src/features.rs
-+++ b/src/tools/tidy/src/features.rs
-@@ -188,7 +188,7 @@ pub fn collect_lang_features(base_src_path: , bad: 
 bool) -> Features {
- }
- 
- let mut parts = line.split(',');
--let level = match parts.next().map(|l| 
l.trim().trim_left_matches('(')) {
-+let level = match parts.next().map(|l| 
l.trim().trim_start_matches('(')) {
- Some("active") => Status::Unstable,
- Some("removed") => Status::Removed,
- Some("accepted") => Status::Stable,
--- 
-2.20.1
-

Deleted: 0001-Revert-1c95f5a34c14f08d65cdd198827e3a2fcb63cf39-9452.patch
===
--- 0001-Revert-1c95f5a34c14f08d65cdd198827e3a2fcb63cf39-9452.patch 
2019-04-12 19:42:29 UTC (rev 350687)
+++ 0001-Revert-1c95f5a34c14f08d65cdd198827e3a2fcb63cf39-9452.patch 
2019-04-12 21:54:30 UTC (rev 350688)
@@ -1,30 +0,0 @@
-From c5f42fa1207dc6df476b55a9cdda439d8cfcba05 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Johannes=20L=C3=B6thberg?= 
-Date: Thu, 14 Mar 2019 20:35:52 +0100
-Subject: [PATCH] Revert 1c95f5a34c14f08d65cdd198827e3a2fcb63cf39 +
- 9452a8dfa3ba3575d5cf090a4e2305ee106d259e
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Signed-off-by: Johannes Löthberg 

- src/librustc_codegen_llvm/debuginfo/metadata.rs | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/librustc_codegen_llvm/debuginfo/metadata.rs 
b/src/librustc_codegen_llvm/debuginfo/metadata.rs
-index 9f63038c36..553b952b56 100644
 a/src/librustc_codegen_llvm/debuginfo/metadata.rs
-+++ b/src/librustc_codegen_llvm/debuginfo/metadata.rs
-@@ -1167,7 +1167,7 @@ fn use_enum_fallback(cx: ) -> bool {
- // LLVM version 7 did not release with an important bug fix;
- // but the required patch is in the LLVM 8.  Rust LLVM reports
- // 8 as well.
--|| llvm_util::get_major_version() < 8;
-+|| llvm_util::get_major_version() < 7;
- }
- 
- // Describes the members of an enum value: An enum is described as a 

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

2017-07-21 Thread Johannes Löthberg
Date: Friday, July 21, 2017 @ 11:40:22
  Author: demize
Revision: 245924

upgpkg: rust 1:1.19.0-1

Added:
  rust/trunk/0001-librustc_llvm-build-Force-link-against-libffi.patch
  rust/trunk/bootstrap-config.toml
Modified:
  rust/trunk/PKGBUILD

--+
 0001-librustc_llvm-build-Force-link-against-libffi.patch |   32 +++
 PKGBUILD |   30 +--
 bootstrap-config.toml|  115 +
 3 files changed, 162 insertions(+), 15 deletions(-)

Added: 0001-librustc_llvm-build-Force-link-against-libffi.patch
===
--- 0001-librustc_llvm-build-Force-link-against-libffi.patch
(rev 0)
+++ 0001-librustc_llvm-build-Force-link-against-libffi.patch2017-07-21 
11:40:22 UTC (rev 245924)
@@ -0,0 +1,32 @@
+From 5dbc650a60ddb230f59e5a18ffd298b033566945 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Johannes=20L=C3=B6thberg?= 
+Date: Thu, 20 Jul 2017 23:07:01 +0200
+Subject: [PATCH] librustc_llvm/build: Force link against libffi
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+`llvm-config --libs` doesn't output libffi in many cases.  Fixing it
+turned out to take quite a bit of effort, so force libffi linking in
+here for now.
+
+Signed-off-by: Johannes Löthberg 
+---
+ src/librustc_llvm/build.rs | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/librustc_llvm/build.rs b/src/librustc_llvm/build.rs
+index 3f0f536960..7dc0c40c9d 100644
+--- a/src/librustc_llvm/build.rs
 b/src/librustc_llvm/build.rs
+@@ -220,6 +220,7 @@ fn main() {
+ };
+ println!("cargo:rustc-link-lib={}={}", kind, name);
+ }
++println!("cargo:rustc-link-lib=dylib=ffi");
+ 
+ // LLVM ldflags
+ //
+-- 
+2.13.3
+

Modified: PKGBUILD
===
--- PKGBUILD2017-07-21 11:38:22 UTC (rev 245923)
+++ PKGBUILD2017-07-21 11:40:22 UTC (rev 245924)
@@ -6,7 +6,7 @@
 
 pkgname=('rust' 'rust-docs')
 epoch=1
-pkgver=1.18.0
+pkgver=1.19.0
 pkgrel=1
 
 pkgdesc='Systems programming language focused on safety, speed and concurrency'
@@ -18,25 +18,25 @@
 
 options=('!emptydirs')
 
-source=("https://static.rust-lang.org/dist/rustc-$pkgver-src.tar.gz"{,.asc})
+source=("https://static.rust-lang.org/dist/rustc-$pkgver-src.tar.gz"{,.asc}
+0001-librustc_llvm-build-Force-link-against-libffi.patch
+bootstrap-config.toml)
 
-sha256sums=('d2dc36e99b9e2269488b2bcddde43c234e6bde03edf70cba82a027ff49c36111'
-'SKIP')
+sha256sums=('15231f5053fb72ad82be91f5abfd6aa60cb7898c5089e4f1ac5910a731090c51'
+'SKIP'
+'563529da8e02f575ddde7247d5fc5350d74031daa54743b86d075f3c45ae2713'
+'8b25eaee73ad3f349300b6d2b752df5e54abaad0555953db1b294294c5a1a6c9')
 validpgpkeys=('108F66205EAEB0AAA8DD5E1C85AB96E6FA1BE5FE') # Rust Language (Tag 
and Release Signing Key) 
 
-build() {
+prepare() {
   cd "rustc-$pkgver-src"
 
-  ./configure \
---prefix=/usr \
---release-channel=stable \
---llvm-root=/usr \
---enable-llvm-link-shared \
---disable-codegen-tests \
---jemalloc-root=/usr/lib \
---enable-local-rust
+  patch -p1 <"$srcdir"/0001-librustc_llvm-build-Force-link-against-libffi.patch
+  cp "$srcdir"/bootstrap-config.toml config.toml
+}
 
-  export RUSTFLAGS="$RUSTFLAGS -C link-args=-lffi"
+build() {
+  cd "rustc-$pkgver-src"
 
   msg2 "Run build under x.py"
   python2 ./x.py build
@@ -48,7 +48,7 @@
 
   cd "rustc-$pkgver-src"
 
-  make DESTDIR="$pkgdir" install
+  DESTDIR="$pkgdir" python2 ./x.py install
 
   for license in APACHE MIT; do install -Dm644 "LICENSE-$license" \
 "$pkgdir/usr/share/licenses/$pkgname/LICENSE-$license"; done

Added: bootstrap-config.toml
===
--- bootstrap-config.toml   (rev 0)
+++ bootstrap-config.toml   2017-07-21 11:40:22 UTC (rev 245924)
@@ -0,0 +1,115 @@
+# All options are commented out by default in this file, and they're commented
+# out with their default values. The build system by default looks for
+# `config.toml` in the current directory of a build for build configuration, 
but
+# a custom configuration file can also be specified with `--config` to the 
build
+# system.
+
+# =
+# Tweaking how LLVM is compiled
+# =
+[llvm]
+
+# Indicates whether ccache is used when building LLVM
+#ccache = false
+# or alternatively ...
+#ccache = "/path/to/ccache"
+
+# LLVM targets to build support for.
+# Note: this is NOT related to Rust compilation targets. However, as Rust is
+# dependent on LLVM for code