summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesse Natalie <jenatali@microsoft.com>2020-11-18 18:29:25 -0800
committerJesse Natalie <jenatali@microsoft.com>2020-12-02 10:12:28 -0800
commit959e0177990356d450da87eda0e7f99039656960 (patch)
treebb703739ba3e49a0b41b5bd317c8c396a608c2e5
parent72566fd92c27b39abe2057f6f23388ec40793dd9 (diff)
clover: Add version.lib dependency for Clang on Windows
Reviewed-by: Karol Herbst <kherbst@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7680>
-rw-r--r--src/gallium/targets/opencl/meson.build10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/gallium/targets/opencl/meson.build b/src/gallium/targets/opencl/meson.build
index e758e4c12d9..243f66e3497 100644
--- a/src/gallium/targets/opencl/meson.build
+++ b/src/gallium/targets/opencl/meson.build
@@ -85,6 +85,14 @@ if not (dep_clang.found() and dep_clang_usable)
endif
endif
+# Be explicit about only using this lib on Windows, to avoid picking
+# up random libs with the generic name 'libversion'
+if host_machine.system() == 'windows'
+ dep_version = cpp.find_library('version')
+else
+ dep_version = null_dep
+endif
+
libopencl = shared_library(
opencl_libname,
[],
@@ -94,7 +102,7 @@ libopencl = shared_library(
link_with : [libpipe_loader_dynamic, libgallium],
dependencies : [
idep_mesautil,
- dep_clock, dep_dl, dep_unwind, dep_elf, dep_clang
+ dep_clock, dep_dl, dep_unwind, dep_elf, dep_clang, dep_version
],
version : '@0@.0.0'.format(opencl_version),
install : true,