disable opencl

This commit is contained in:
h00465007 2020-01-15 18:43:44 +08:00
parent 89306b8081
commit 3e865db49d

View File

@ -21,10 +21,12 @@
%global sanitize 0 %global sanitize 0
%define with_opencl 0
Name: mesa Name: mesa
Summary: Mesa graphics libraries Summary: Mesa graphics libraries
Version: 18.2.2 Version: 18.2.2
Release: 5 Release: 6
License: MIT License: MIT
URL: https://www.mesa3d.org URL: https://www.mesa3d.org
Source0: https://mesa.freedesktop.org/archive/%{name}-%{version}.tar.xz Source0: https://mesa.freedesktop.org/archive/%{name}-%{version}.tar.xz
@ -39,7 +41,11 @@ BuildRequires: xorg-x11-proto-devel imake libselinux-devel libXrandr-devel libX
BuildRequires: libXi-devel libXmu-devel libxshmfence-devel elfutils python3 python2 gettext llvm-devel clang-devel BuildRequires: libXi-devel libXmu-devel libxshmfence-devel elfutils python3 python2 gettext llvm-devel clang-devel
BuildRequires: elfutils-libelf-devel python3-libxml2 python2-libxml2 libudev-devel bison flex BuildRequires: elfutils-libelf-devel python3-libxml2 python2-libxml2 libudev-devel bison flex
BuildRequires: wayland-devel wayland-protocols-devel libvdpau-devel libva-devel zlib-devel BuildRequires: wayland-devel wayland-protocols-devel libvdpau-devel libva-devel zlib-devel
BuildRequires: libomxil-bellagio-devel libclc-devel opencl-filesystem vulkan-devel python3-mako python2-mako BuildRequires: libomxil-bellagio-devel libclc-devel vulkan-devel python3-mako python2-mako
%if 0%{?with_opencl}
BuildRequires: opencl-filesystem
%endif
%ifarch %{valgrind_arches} %ifarch %{valgrind_arches}
BuildRequires: valgrind-devel BuildRequires: valgrind-devel
%endif %endif
@ -179,6 +185,7 @@ Provides: libglapi libglapi%{?_isa}
%description libglapi %description libglapi
%{summary}. %{summary}.
%if 0%{?with_opencl}
%package libOpenCL %package libOpenCL
Summary: Mesa OpenCL runtime library Summary: Mesa OpenCL runtime library
Requires: ocl-icd%{?_isa} Requires: ocl-icd%{?_isa}
@ -195,6 +202,7 @@ Requires: %{name}-libOpenCL%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{rele
%description libOpenCL-devel %description libOpenCL-devel
%{summary}. %{summary}.
%endif
%package libd3d %package libd3d
Summary: Mesa Direct3D9 state tracker Summary: Mesa Direct3D9 state tracker
@ -281,6 +289,12 @@ mkdir -p %{buildroot}/%{_includedir}/vulkan/
rm -f %{buildroot}/%{_includedir}/vulkan/vk_platform.h rm -f %{buildroot}/%{_includedir}/vulkan/vk_platform.h
rm -f %{buildroot}/%{_includedir}/vulkan/vulkan.h rm -f %{buildroot}/%{_includedir}/vulkan/vulkan.h
%if ! 0%{?with_opencl}
rm -f %{buildroot}%{_libdir}/libMesaOpenCL.so.*
rm -f %{buildroot}%{_sysconfdir}/OpenCL/vendors/mesa.icd
rm -f %{buildroot}%{_libdir}/libMesaOpenCL.so
%endif
%delete_la %delete_la
pushd %{buildroot}%{_libdir} pushd %{buildroot}%{_libdir}
@ -293,7 +307,9 @@ popd
%ldconfig_scriptlets libOSMesa %ldconfig_scriptlets libOSMesa
%ldconfig_scriptlets libgbm %ldconfig_scriptlets libgbm
%ldconfig_scriptlets libxatracker %ldconfig_scriptlets libxatracker
%if 0%{?with_opencl}
%ldconfig_scriptlets libOpenCL %ldconfig_scriptlets libOpenCL
%endif
%files filesystem %files filesystem
%defattr(-,root,root) %defattr(-,root,root)
@ -369,6 +385,7 @@ popd
%{_includedir}/xa_*.h %{_includedir}/xa_*.h
%{_libdir}/pkgconfig/xatracker.pc %{_libdir}/pkgconfig/xatracker.pc
%if 0%{?with_opencl}
%files libOpenCL %files libOpenCL
%defattr(-,root,root) %defattr(-,root,root)
%{_libdir}/libMesaOpenCL.so.* %{_libdir}/libMesaOpenCL.so.*
@ -377,6 +394,7 @@ popd
%files libOpenCL-devel %files libOpenCL-devel
%defattr(-,root,root) %defattr(-,root,root)
%{_libdir}/libMesaOpenCL.so %{_libdir}/libMesaOpenCL.so
%endif
%files libd3d %files libd3d
%defattr(-,root,root) %defattr(-,root,root)
@ -443,19 +461,22 @@ popd
%{_includedir}/vulkan/ %{_includedir}/vulkan/
%changelog %changelog
* Sat Oct 19 2019 openEuler Buildteam <buildteam@openeuler.org> - 19.2.2-5 * Wed Jan 15 2020 openEuler Buildteam <buildteam@openeuler.org> - 18.2.2-6
- disable opencl
* Sat Oct 19 2019 openEuler Buildteam <buildteam@openeuler.org> - 18.2.2-5
- Type:bugfix - Type:bugfix
- Id:NA - Id:NA
- SUG:NA - SUG:NA
- DESC:add the license file - DESC:add the license file
* Tue Sep 24 2019 openEuler Buildteam <buildteam@openeuler.org> - 19.2.2-4 * Tue Sep 24 2019 openEuler Buildteam <buildteam@openeuler.org> - 18.2.2-4
- Type: enhance - Type: enhance
- Id:NA - Id:NA
- SUG:NA - SUG:NA
- DESC: rewrite it without merging packages - DESC: rewrite it without merging packages
* Sat Sep 21 2019 openEuler Buildteam <buildteam@openeuler.org> - 19.2.2-3 * Sat Sep 21 2019 openEuler Buildteam <buildteam@openeuler.org> - 18.2.2-3
- Type:bugfix - Type:bugfix
- Id:NA - Id:NA
- SUG:NA - SUG:NA