Index: scripts/Xcode/build-llvm.py =================================================================== --- scripts/Xcode/build-llvm.py +++ scripts/Xcode/build-llvm.py @@ -5,6 +5,7 @@ import fnmatch import os import platform +import re import subprocess import sys @@ -132,7 +133,9 @@ def collect_archives_in_path (path): files = os.listdir(path) - return [os.path.join(path, file) for file in files if file.endswith(".a")] + # Only use libclang and libLLVM archives, and exclude libclang_rt + regexp = "^lib(clang[^_]|LLVM).*$" + return [os.path.join(path, file) for file in files if file.endswith(".a") and re.match(regexp, file)] def archive_list (): paths = library_paths()