$OpenBSD: patch-src_bootstrap_bin_rustc_rs,v 1.14 2020/03/21 05:23:59 semarie Exp $
try to reduce memory usage on aarch64:
 - reduce memory use by retaining fewer names within compilation artifacts
Index: src/bootstrap/bin/rustc.rs
--- src/bootstrap/bin/rustc.rs.orig
+++ src/bootstrap/bin/rustc.rs
@@ -115,6 +115,12 @@ fn main() {
             Err(..) => "n",
         };
 
+        if target.unwrap().contains("aarch64-unknown-openbsd")
+            && crate_name == Some("rustc") {
+
+            cmd.arg("-Z").arg("fewer-names");
+        }
+
         // The compiler builtins are pretty sensitive to symbols referenced in
         // libcore and such, so we never compile them with debug assertions.
         //
