summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meson.build12
1 files changed, 10 insertions, 2 deletions
diff --git a/meson.build b/meson.build
index 323f7062715..cb3b6587b4d 100644
--- a/meson.build
+++ b/meson.build
@@ -992,15 +992,23 @@ if with_gallium_opencl
# TODO: optional modules
endif
+if with_amd_vk
+ _llvm_version = '>= 4.0.0'
+elif with_gallium_opencl or with_gallium_swr or with_gallium_r600 or with_gallium_radeonsi
+ _llvm_version = '>= 3.9.0'
+else
+ _llvm_version = '>= 3.3.0'
+endif
+
_llvm = get_option('llvm')
if _llvm == 'auto'
dep_llvm = dependency(
- 'llvm', version : '>= 3.9.0', modules : llvm_modules,
+ 'llvm', version : _llvm_version, modules : llvm_modules,
required : with_amd_vk or with_gallium_radeonsi or with_gallium_swr or with_gallium_opencl,
)
with_llvm = dep_llvm.found()
elif _llvm == 'true'
- dep_llvm = dependency('llvm', version : '>= 3.9.0', modules : llvm_modules)
+ dep_llvm = dependency('llvm', version : _llvm_version, modules : llvm_modules)
with_llvm = true
else
dep_llvm = []