diff options
author | Alyssa Ross <hi@alyssa.is> | 2021-10-19 14:40:23 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2022-01-07 10:22:32 +0000 |
commit | cc62bcb55359ba8c5e0fe3a48e778444c89060d8 (patch) | |
tree | ca0e21d44eaf8837b687395e614445f7761d7bbd /nixpkgs/pkgs/development/libraries/mesa/opencl.patch | |
parent | d6625e8d25efd829c3cfa227d025ca4e606ae4b7 (diff) | |
parent | a323570a264da96a0b0bcc1c9aa017794acdc752 (diff) | |
download | nixlib-cc62bcb55359ba8c5e0fe3a48e778444c89060d8.tar nixlib-cc62bcb55359ba8c5e0fe3a48e778444c89060d8.tar.gz nixlib-cc62bcb55359ba8c5e0fe3a48e778444c89060d8.tar.bz2 nixlib-cc62bcb55359ba8c5e0fe3a48e778444c89060d8.tar.lz nixlib-cc62bcb55359ba8c5e0fe3a48e778444c89060d8.tar.xz nixlib-cc62bcb55359ba8c5e0fe3a48e778444c89060d8.tar.zst nixlib-cc62bcb55359ba8c5e0fe3a48e778444c89060d8.zip |
Merge commit 'a323570a264da96a0b0bcc1c9aa017794acdc752'
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/mesa/opencl.patch')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/mesa/opencl.patch | 70 |
1 files changed, 70 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/mesa/opencl.patch b/nixpkgs/pkgs/development/libraries/mesa/opencl.patch new file mode 100644 index 000000000000..ce6e3d575085 --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/mesa/opencl.patch @@ -0,0 +1,70 @@ +diff --git a/meson_options.txt b/meson_options.txt +index a7030aba31e..1d2d8814992 100644 +--- a/meson_options.txt ++++ b/meson_options.txt +@@ -18,6 +18,12 @@ + # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + # SOFTWARE. + ++option( ++ 'clang-libdir', ++ type : 'string', ++ value : '', ++ description : 'Locations to search for clang libraries.' ++) + option( + 'platforms', + type : 'array', +diff --git a/src/gallium/targets/opencl/meson.build b/src/gallium/targets/opencl/meson.build +index b77826b6e1e..14fa9ba7177 100644 +--- a/src/gallium/targets/opencl/meson.build ++++ b/src/gallium/targets/opencl/meson.build +@@ -30,6 +30,7 @@ if with_ld_version_script + endif + + llvm_libdir = dep_llvm.get_variable(cmake : 'LLVM_LIBRARY_DIR', configtool: 'libdir') ++clang_libdir = get_option('clang-libdir') + opencl_libname = with_opencl_icd ? 'MesaOpenCL' : 'OpenCL' + + polly_dep = null_dep +@@ -60,19 +61,19 @@ else + endif + if not (dep_clang.found() and dep_clang_usable) + dep_clang = [ +- 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('clangASTMatchers', 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('clangCodeGen', dirs : clang_libdir), ++ cpp.find_library('clangFrontendTool', dirs : clang_libdir), ++ cpp.find_library('clangFrontend', dirs : clang_libdir), ++ cpp.find_library('clangDriver', dirs : clang_libdir), ++ cpp.find_library('clangSerialization', dirs : clang_libdir), ++ cpp.find_library('clangParse', dirs : clang_libdir), ++ cpp.find_library('clangSema', dirs : clang_libdir), ++ cpp.find_library('clangAnalysis', dirs : clang_libdir), ++ cpp.find_library('clangAST', dirs : clang_libdir), ++ cpp.find_library('clangASTMatchers', dirs : clang_libdir), ++ cpp.find_library('clangEdit', dirs : clang_libdir), ++ cpp.find_library('clangLex', dirs : clang_libdir), ++ cpp.find_library('clangBasic', dirs : clang_libdir), + polly_dep, polly_isl_dep, + ] + # check clang once more +@@ -120,6 +121,6 @@ if with_opencl_icd + input : 'mesa.icd.in', + output : 'mesa.icd', + install : true, +- install_dir : join_paths(get_option('sysconfdir'), 'OpenCL', 'vendors'), ++ install_dir : join_paths(get_option('prefix'), 'etc', 'OpenCL', 'vendors'), + ) + endif |