From 0e67fc745010aea9cf2d4e64a44d71b7f37a63e5 Mon Sep 17 00:00:00 2001 From: Araq Date: Tue, 21 Nov 2017 01:45:03 +0100 Subject: [PATCH] OS X has no llvm-ar tool; use ar instead --- compiler/extccomp.nim | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/compiler/extccomp.nim b/compiler/extccomp.nim index 4614eafe6d..cac3a6e9f9 100644 --- a/compiler/extccomp.nim +++ b/compiler/extccomp.nim @@ -95,7 +95,11 @@ compiler llvmGcc: result.name = "llvm_gcc" result.compilerExe = "llvm-gcc" result.cppCompiler = "llvm-g++" - result.buildLib = "llvm-ar rcs $libfile $objfiles" + when defined(macosx): + # OS X has no 'llvm-ar' tool: + result.buildLib = "ar rcs $libfile $objfiles" + else: + result.buildLib = "llvm-ar rcs $libfile $objfiles" # Clang (LLVM) C/C++ Compiler compiler clang: