Bug 1398082 - Support compiling stylo with llvm-config-5.0 or llvm-config-6.0. r=froydnj
authorJan Keromnes <janx@linux.com>
Tue, 12 Sep 2017 13:04:00 -0400
changeset 429847 781bc2a066f2d8fab47e1c8c897491c1c488fbed
parent 429846 cdaed5454569de4a3bce86b2d6e2a7543f67a658
child 429848 247dc838b340fde94190960728510972e955c312
push id7761
push userjlund@mozilla.com
push dateFri, 15 Sep 2017 00:19:52 +0000
treeherdermozilla-beta@c38455951db4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersfroydnj
bugs1398082
milestone57.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1398082 - Support compiling stylo with llvm-config-5.0 or llvm-config-6.0. r=froydnj
toolkit/moz.configure
--- a/toolkit/moz.configure
+++ b/toolkit/moz.configure
@@ -613,24 +613,25 @@ def building_stylo_bindgen(stylo_config,
 # configure options.  The Windows installer of LLVM/Clang doesn't provide
 # llvm-config, so we need both methods to support all of our tier-1
 # platforms.
 @depends(host)
 @imports('which')
 @imports('os')
 @imports('subprocess')
 def llvm_config_paths(host):
-    llvm_config_progs = [
-        'llvm-config-4.0',
-        'llvm-config-mp-4.0',   # MacPorts' chosen naming scheme.
-        'llvm-config40',
-        'llvm-config-3.9',
-        'llvm-config39',
-        'llvm-config',
-    ]
+    llvm_supported_versions = ['6.0', '5.0', '4.0', '3.9']
+    llvm_config_progs = []
+    for version in llvm_supported_versions:
+        llvm_config_progs += [
+            'llvm-config-%s' % version,
+            'llvm-config-mp-%s' % version,    # MacPorts' chosen naming scheme.
+            'llvm-config%s' % version.replace('.', ''),
+        ]
+    llvm_config_progs.append('llvm-config')
 
     # Homebrew on macOS doesn't make clang available on PATH, so we have to
     # look for it in non-standard places.
     if host.kernel == 'Darwin':
         try:
             brew = which.which('brew')
             brew_config = subprocess.check_output([brew, 'config']).strip()