From f33c67cb4967e09cc3cf144bce702aa52687d9e8618808089bb23d7b2e0e2ca9 Mon Sep 17 00:00:00 2001 From: Stefan Dirsch Date: Thu, 26 Sep 2019 12:26:35 +0000 Subject: [PATCH] Accepting request 733402 from home:aaronpuchert:llvm-next - n_opencl_dep_libclang.patch * Link OpenCL library with libclang-cpp.so instead of the component libraries for LLVM >= 9. OBS-URL: https://build.opensuse.org/request/show/733402 OBS-URL: https://build.opensuse.org/package/show/X11:XOrg/Mesa?expand=0&rev=865 --- Mesa-drivers.changes | 7 +++++++ Mesa-drivers.spec | 6 ++++++ Mesa.changes | 7 +++++++ Mesa.spec | 6 ++++++ n_opencl_dep_libclang.patch | 40 +++++++++++++++++++++++++++++++++++++ 5 files changed, 66 insertions(+) create mode 100644 n_opencl_dep_libclang.patch diff --git a/Mesa-drivers.changes b/Mesa-drivers.changes index ca7b6ad..ac2d4d1 100644 --- a/Mesa-drivers.changes +++ b/Mesa-drivers.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed Sep 25 18:34:34 UTC 2019 - Aaron Puchert + +- n_opencl_dep_libclang.patch + * Link OpenCL library with libclang-cpp.so instead of the + component libraries for LLVM >= 9. + ------------------------------------------------------------------- Wed Sep 25 18:00:45 UTC 2019 - Stefan Dirsch diff --git a/Mesa-drivers.spec b/Mesa-drivers.spec index f90da6c..eafca1c 100644 --- a/Mesa-drivers.spec +++ b/Mesa-drivers.spec @@ -125,6 +125,7 @@ Source4: manual-pages.tar.bz2 Source6: %{name}-rpmlintrc Source7: Mesa.keyring Patch0: U_llvmpipe-Don-t-use-u_ringbuffer-for-lp_scene_queue.patch +Patch1: n_opencl_dep_libclang.patch # never to be upstreamed Patch54: n_drirc-disable-rgb10-for-chromium-on-amd.patch Patch58: u_dep_xcb.patch @@ -731,6 +732,11 @@ programs against the XA state tracker. rm -rf docs/README.{VMS,WIN32,OS2} %patch0 -p1 +%if 0%{with_llvm} +%if %{_llvm_sonum} >= 9 +%patch1 -p1 +%endif +%endif %patch54 -p1 %patch58 -p1 %patch60 -p1 diff --git a/Mesa.changes b/Mesa.changes index ca7b6ad..ac2d4d1 100644 --- a/Mesa.changes +++ b/Mesa.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed Sep 25 18:34:34 UTC 2019 - Aaron Puchert + +- n_opencl_dep_libclang.patch + * Link OpenCL library with libclang-cpp.so instead of the + component libraries for LLVM >= 9. + ------------------------------------------------------------------- Wed Sep 25 18:00:45 UTC 2019 - Stefan Dirsch diff --git a/Mesa.spec b/Mesa.spec index c4a94dd..87787bb 100644 --- a/Mesa.spec +++ b/Mesa.spec @@ -124,6 +124,7 @@ Source4: manual-pages.tar.bz2 Source6: %{name}-rpmlintrc Source7: Mesa.keyring Patch0: U_llvmpipe-Don-t-use-u_ringbuffer-for-lp_scene_queue.patch +Patch1: n_opencl_dep_libclang.patch # never to be upstreamed Patch54: n_drirc-disable-rgb10-for-chromium-on-amd.patch Patch58: u_dep_xcb.patch @@ -730,6 +731,11 @@ programs against the XA state tracker. rm -rf docs/README.{VMS,WIN32,OS2} %patch0 -p1 +%if 0%{with_llvm} +%if %{_llvm_sonum} >= 9 +%patch1 -p1 +%endif +%endif %patch54 -p1 %patch58 -p1 %patch60 -p1 diff --git a/n_opencl_dep_libclang.patch b/n_opencl_dep_libclang.patch new file mode 100644 index 0000000..15c0934 --- /dev/null +++ b/n_opencl_dep_libclang.patch @@ -0,0 +1,40 @@ +From 993bc3af95819bb9a4354b7da2ddb7cfe196f90b Mon Sep 17 00:00:00 2001 +From: Aaron Puchert +Date: Wed, 25 Sep 2019 18:34:34 +0000 +Subject: [PATCH] Link with clang-cpp instead of Clang component libraries + +Since LLVM 9, the Clang C++ API is exposed via the new clang-cpp target, +and the component libraries need no longer be packaged [1]. + +[1] https://releases.llvm.org/9.0.0/tools/clang/docs/ReleaseNotes.html#build-system-changes +--- + src/gallium/targets/opencl/meson.build | 13 +------------ + 1 file changed, 1 insertion(+), 12 deletions(-) + +diff --git a/src/gallium/targets/opencl/meson.build b/src/gallium/targets/opencl/meson.build +index 317ad8dab4a..5fc00390b00 100644 +--- a/src/gallium/targets/opencl/meson.build ++++ b/src/gallium/targets/opencl/meson.build +@@ -42,18 +42,7 @@ libopencl = shared_library( + link_with : [libpipe_loader_dynamic, libgallium, libmesa_util], + dependencies : [ + dep_thread, dep_clock, dep_dl, dep_unwind, dep_elf, dep_expat, +- cpp.find_library('clangCodeGen', dirs : llvm_libdir), +- cpp.find_library('clangFrontendTool', dirs : llvm_libdir), +- cpp.find_library('clangFrontend', dirs : llvm_libdir), +- cpp.find_library('clangDriver', dirs : llvm_libdir), +- cpp.find_library('clangSerialization', dirs : llvm_libdir), +- cpp.find_library('clangParse', dirs : llvm_libdir), +- cpp.find_library('clangSema', dirs : llvm_libdir), +- cpp.find_library('clangAnalysis', dirs : llvm_libdir), +- cpp.find_library('clangAST', dirs : llvm_libdir), +- cpp.find_library('clangEdit', dirs : llvm_libdir), +- cpp.find_library('clangLex', dirs : llvm_libdir), +- cpp.find_library('clangBasic', dirs : llvm_libdir), ++ cpp.find_library('clang-cpp', dirs : llvm_libdir), + ], + version : '@0@.0.0'.format(opencl_version), + install : true, +-- +2.23.0 +