From 80952c89040f791fd280589c7ecde5fcee299b76 Mon Sep 17 00:00:00 2001 From: ilovezfs Date: Fri, 12 Jan 2018 10:31:26 -0800 Subject: [PATCH] rust: fix build on 10.13 with APFS (#22796) --- Formula/rust.rb | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Formula/rust.rb b/Formula/rust.rb index bf2030ecf8..4f4bde05df 100644 --- a/Formula/rust.rb +++ b/Formula/rust.rb @@ -57,6 +57,15 @@ class Rust < Formula end def install + # Remove for > 1.23.0; fix build failure on APFS + # See https://github.com/rust-lang/cargo/pull/4739 + if build.stable? && MacOS.version >= :high_sierra + inreplace "src/stage0.txt" do |s| + s.gsub! "date: 2017-11-20", "date: 2017-11-23" + s.gsub! "rustc: 1.22.0", "rustc: 1.22.1" + end + end + # Fix build failure for compiler_builtins "error: invalid deployment target # for -stdlib=libc++ (requires OS X 10.7 or later)" ENV["MACOSX_DEPLOYMENT_TARGET"] = MacOS.version