about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2014-01-16 12:18:22 -0800
committerAlex Crichton <alex@alexcrichton.com>2014-01-16 12:18:22 -0800
commit11dcd9a0970037042331ffba5e3b2c787d7ff614 (patch)
treecc1d417785c7857022e2358717455f4ef3aba7a4
parent77eeddaa481fa083dfa857e5d7dd7f5ab784a9f1 (diff)
downloadrust-11dcd9a0970037042331ffba5e3b2c787d7ff614.tar.gz
rust-11dcd9a0970037042331ffba5e3b2c787d7ff614.zip
Don't run 'ar s' on OSX
Apparently this isn't necessary, and it's just causing problems.

Closes #11162
-rw-r--r--src/librustc/back/link.rs11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/librustc/back/link.rs b/src/librustc/back/link.rs
index ffb9cce033e..8948727c7bd 100644
--- a/src/librustc/back/link.rs
+++ b/src/librustc/back/link.rs
@@ -924,10 +924,13 @@ fn link_rlib(sess: Session,
                 fs::unlink(&bc);
             }
 
-            // Now that we've added files, some platforms need us to now update
-            // the symbol table in the archive (because some platforms die when
-            // adding files to the archive without symbols).
-            a.update_symbols();
+            // After adding all files to the archive, we need to update the
+            // symbol table of the archive. This currently dies on OSX (see
+            // #11162), and isn't necessary there anyway
+            match sess.targ_cfg.os {
+                abi::OsMacos => {}
+                _ => { a.update_symbols(); }
+            }
         }
 
         None => {}