|
@@ -3,51 +3,64 @@
|
|
%bcond_with libva
|
|
%bcond_with libva
|
|
%bcond_with glvnd
|
|
%bcond_with glvnd
|
|
|
|
|
|
-%define _unpackaged_files_terminate_build 1
|
|
+%global with_hardware 1
|
|
|
|
+%global with_vdpau 1
|
|
|
|
+#global with_vaapi 1
|
|
|
|
+%global with_nine 1
|
|
|
|
+#global with_omx 1
|
|
|
|
+#global with_opencl 1
|
|
|
|
+%global base_drivers nouveau,r100,r200
|
|
|
|
|
|
-%define base_drivers swrast,nouveau,radeon,r200
|
|
|
|
%ifarch %{ix86}
|
|
%ifarch %{ix86}
|
|
%define ix86_drivers ,i915,i965
|
|
%define ix86_drivers ,i915,i965
|
|
%endif
|
|
%endif
|
|
%ifarch x86_64
|
|
%ifarch x86_64
|
|
%define amd64_drivers ,i915,i965
|
|
%define amd64_drivers ,i915,i965
|
|
%endif
|
|
%endif
|
|
-%define dri_drivers --with-dri-drivers=%{base_drivers}%{?ix86_drivers}%{?amd64_drivers}
|
|
+%define dri_drivers %{base_drivers}%{?ix86_drivers}%{?amd64_drivers}
|
|
|
|
|
|
-%ifarch %{ix86} x86_64
|
|
+%global with_iris 1
|
|
-#define with_opencl 1
|
|
+%global with_vmware 1
|
|
|
|
+%global with_xa 1
|
|
%if %{with vulkan}
|
|
%if %{with vulkan}
|
|
-%define vulkan_drivers --with-vulkan-drivers=intel,radeon
|
|
+%global vulkan_drivers intel,amd
|
|
-%endif
|
|
+%else
|
|
|
|
+%global vulkan_drivers %{nil}
|
|
%endif
|
|
%endif
|
|
|
|
+%global with_radeonsi 1
|
|
|
|
+%global with_asm 1
|
|
|
|
|
|
-%define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
|
|
|
|
|
|
|
|
-Summary: Mesa graphics libraries
|
|
+%define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
|
|
-Summary(ja): Mesa グラフィックスライブラリ
|
|
|
|
-Name: mesa
|
|
|
|
-Version: 18.2.6
|
|
|
|
-Release: 1%{?_dist_release}
|
|
|
|
-License: MIT
|
|
|
|
-Group: System Environment/Libraries
|
|
|
|
-URL: http://www.mesa3d.org
|
|
|
|
|
|
|
|
-Vendor: Project Vine
|
|
+Summary: Mesa graphics libraries
|
|
-Distribution: Vine Linux
|
|
+Summary(ja): Mesa グラフィックスライブラリ
|
|
|
|
+Name: mesa
|
|
|
|
+Version: 19.1.7
|
|
|
|
+Release: 1%{?_dist_release}
|
|
|
|
+License: MIT
|
|
|
|
+Group: System Environment/Libraries
|
|
|
|
+Vendor: Project Vine
|
|
|
|
+Distribution: Vine Linux
|
|
|
|
+URL: https://www.mesa3d.org/
|
|
|
|
+Source0: https://mesa.freedesktop.org/archive/%{name}-%{version}.tar.xz
|
|
|
|
+
|
|
|
|
+Source2: glesv2.pc
|
|
|
|
+Source3: egl.pc
|
|
|
|
|
|
-Source0: ftp://ftp.freedesktop.org/pub/mesa/%{version}/%{name}-%{version}.tar.xz
|
|
|
|
-Source1: vl_decoder.c
|
|
|
|
-Source2: vl_mpeg12_decoder.c
|
|
|
|
-Source3: Makefile
|
|
|
|
# src/gallium/auxiliary/postprocess/pp_mlaa* have an ... interestingly worded license.
|
|
# src/gallium/auxiliary/postprocess/pp_mlaa* have an ... interestingly worded license.
|
|
# Source4 contains email correspondence clarifying the license terms.
|
|
# Source4 contains email correspondence clarifying the license terms.
|
|
# Fedora opts to ignore the optional part of clause 2 and treat that code as 2 clause BSD.
|
|
# Fedora opts to ignore the optional part of clause 2 and treat that code as 2 clause BSD.
|
|
Source4: Mesa-MLAA-License-Clarification-Email.txt
|
|
Source4: Mesa-MLAA-License-Clarification-Email.txt
|
|
|
|
|
|
-Patch1: 0001-llvm-SONAME-without-version.patch
|
|
|
|
Patch3: 0003-evergreen-big-endian.patch
|
|
Patch3: 0003-evergreen-big-endian.patch
|
|
|
|
|
|
|
|
+# Disable rgb10 configs by default:
|
|
|
|
+# https://bugzilla.redhat.com/show_bug.cgi?id=1560481
|
|
|
|
+Patch7: 0001-gallium-Disable-rgb10-configs-by-default.patch
|
|
|
|
+
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
|
|
|
|
+BuildRequires: meson
|
|
BuildRequires: pkgconfig
|
|
BuildRequires: pkgconfig
|
|
BuildRequires: flex, bison
|
|
BuildRequires: flex, bison
|
|
BuildRequires: libstdc++-static
|
|
BuildRequires: libstdc++-static
|
|
@@ -66,10 +79,14 @@ BuildRequires: libXmu-devel
|
|
BuildRequires: libXrandr-devel
|
|
BuildRequires: libXrandr-devel
|
|
BuildRequires: libxshmfence-devel
|
|
BuildRequires: libxshmfence-devel
|
|
BuildRequires: eudev-libudev-devel
|
|
BuildRequires: eudev-libudev-devel
|
|
-BuildRequires: llvm-devel >= 7.0.0
|
|
+BuildRequires: llvm-devel >= 9.0.0
|
|
%if 0%{?with_opencl}
|
|
%if 0%{?with_opencl}
|
|
BuildRequires: clang-devel >= 3.3
|
|
BuildRequires: clang-devel >= 3.3
|
|
%endif
|
|
%endif
|
|
|
|
+BuildRequires: python3-devel
|
|
|
|
+BuildRequires: python3-rpm-macros
|
|
|
|
+BuildRequires: python3-setuptools
|
|
|
|
+BuildRequires: python3-mako
|
|
BuildRequires: libxml2-python
|
|
BuildRequires: libxml2-python
|
|
BuildRequires: libvdpau-devel >= 1.1
|
|
BuildRequires: libvdpau-devel >= 1.1
|
|
BuildRequires: elfutils-libelf-devel
|
|
BuildRequires: elfutils-libelf-devel
|
|
@@ -244,6 +261,22 @@ Provides: libxatracker-devel
|
|
%description libxatracker-devel
|
|
%description libxatracker-devel
|
|
Mesa XA state tracker development package
|
|
Mesa XA state tracker development package
|
|
|
|
|
|
|
|
+%if 0%{?with_nine}
|
|
|
|
+%package libd3d
|
|
|
|
+Group: System Environment/Libraries
|
|
|
|
+Summary: Mesa Direct3D9 state tracker
|
|
|
|
+
|
|
|
|
+%description libd3d
|
|
|
|
+%{summary}.
|
|
|
|
+
|
|
|
|
+%package libd3d-devel
|
|
|
|
+Summary: Mesa Direct3D9 state tracker development package
|
|
|
|
+Group: Development/Libraries
|
|
|
|
+Requires: %{name}-libd3d%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release}
|
|
|
|
+
|
|
|
|
+%description libd3d-devel
|
|
|
|
+%{summary}.
|
|
|
|
+%endif
|
|
|
|
|
|
%package source
|
|
%package source
|
|
Summary: Mesa source code required to build X server
|
|
Summary: Mesa source code required to build X server
|
|
@@ -409,77 +442,60 @@ Headers for development with the Vulkan API.
|
|
|
|
|
|
%prep
|
|
%prep
|
|
%autosetup -n %{name}-%{version} -p1
|
|
%autosetup -n %{name}-%{version} -p1
|
|
-cp -f %{SOURCE1} src/gallium/auxiliary/vl/vl_decoder.c
|
|
+cp %{SOURCE2} .
|
|
-cp -f %{SOURCE2} src/gallium/auxiliary/vl/vl_mpeg12_decoder.c
|
|
+cp %{SOURCE3} .
|
|
|
|
|
|
cp %{SOURCE4} docs/
|
|
cp %{SOURCE4} docs/
|
|
|
|
|
|
|
|
|
|
%build
|
|
%build
|
|
|
|
|
|
-autoreconf -vfi
|
|
+%meson -Dcpp_std=gnu++11 \
|
|
-
|
|
+ -Dplatforms=x11,drm,surfaceless \
|
|
-# C++ note: we never say "catch" in the source. we do say "typeid" once,
|
|
+ -Ddri3=true \
|
|
-# in an assert, which is patched out above. LLVM doesn't use RTTI or throw.
|
|
+ -Ddri-drivers=%{?dri_drivers} \
|
|
-#
|
|
+%if 0%{?with_hardware}
|
|
-# We do say 'catch' in the clover and d3d1x state trackers, but we're not
|
|
+ -Dgallium-drivers=swrast,virgl,r300,nouveau%{?with_iris:,iris}%{?with_vmware:,svga}%{?with_radeonsi:,radeonsi,r600}%{?with_freedreno:,freedreno}%{?with_etnaviv:,etnaviv}%{?with_tegra:,tegra}%{?with_vc4:,vc4}%{?with_v3d:,v3d}%{?with_kmsro:,kmsro}%{?with_lima:,lima}%{?with_panfrost:,panfrost} \
|
|
-# building those yet.
|
|
+%else
|
|
-export CXXFLAGS="%{?with_opencl:-frtti -fexceptions} %{!?with_opencl:-fno-rtti -fno-exceptions}"
|
|
+ -Dgallium-drivers=swrast,virgl \
|
|
-export LDFLAGS="-static-libstdc++"
|
|
|
|
-%ifarch %{ix86}
|
|
|
|
-# i do not have words for how much the assembly dispatch code infuriates me
|
|
|
|
-%global asm_flags --disable-asm
|
|
|
|
%endif
|
|
%endif
|
|
-
|
|
+ -Dgallium-vdpau=%{?with_vdpau:true}%{!?with_vdpau:false} \
|
|
-# now build the rest of mesa
|
|
+ -Dgallium-xvmc=false \
|
|
-%configure \
|
|
+ -Dgallium-omx=%{?with_omx:bellagio}%{!?with_omx:disabled} \
|
|
- %{?asm_flags} \
|
|
+ -Dgallium-va=%{?with_vaapi:true}%{!?with_vaapi:false} \
|
|
|
|
+ -Dgallium-xa=%{?with_xa:true}%{!?with_xa:false} \
|
|
|
|
+ -Dgallium-nine=%{?with_nine:true}%{!?with_nine:false} \
|
|
|
|
+ -Dgallium-opencl=%{?with_opencl:icd}%{!?with_opencl:disabled} \
|
|
|
|
+ -Dvulkan-drivers=%{?vulkan_drivers} \
|
|
|
|
+ -Dshared-glapi=true \
|
|
|
|
+ -Dgles1=false \
|
|
|
|
+ -Dgles2=true \
|
|
|
|
+ -Dopengl=true \
|
|
|
|
+ -Dgbm=true \
|
|
|
|
+ -Dglx=dri \
|
|
|
|
+ -Degl=true \
|
|
%if %{with glvnd}
|
|
%if %{with glvnd}
|
|
- --enable-libglvnd \
|
|
+ -Dglvnd=true \
|
|
-%endif
|
|
+%else
|
|
- --disable-selinux \
|
|
+ -Dglvnd=false \
|
|
- --enable-gallium-osmesa \
|
|
|
|
- --with-dri-driverdir=%{_libdir}/dri \
|
|
|
|
- --enable-egl \
|
|
|
|
- --enable-gles1 \
|
|
|
|
- --enable-gles2 \
|
|
|
|
- --disable-xvmc \
|
|
|
|
- --enable-vdpau \
|
|
|
|
-%if %{with libva}
|
|
|
|
- --enable-va \
|
|
|
|
-%endif
|
|
|
|
- --with-platforms=x11,drm,surfaceless \
|
|
|
|
- --enable-shared-glapi \
|
|
|
|
- --enable-gbm \
|
|
|
|
- %{?with_opencl:--enable-opencl --enable-opencl-icd} %{!?with_opencl:--disable-opencl} \
|
|
|
|
- --enable-glx-tls \
|
|
|
|
- --enable-texture-float=yes \
|
|
|
|
-%if %{with vulkan}
|
|
|
|
- %{?vulkan_drivers} \
|
|
|
|
%endif
|
|
%endif
|
|
- --enable-gallium-llvm \
|
|
+ -Dasm=%{?with_asm:true}%{!?with_asm:false} \
|
|
- --enable-llvm \
|
|
+ -Dllvm=true \
|
|
- --with-llvm-shared-libs \
|
|
+ -Dshared-llvm=true \
|
|
- --enable-dri \
|
|
+ -Dvalgrind=%{?with_valgrind:true}%{!?with_valgrind:false} \
|
|
- --enable-xa \
|
|
+ -Dbuild-tests=false \
|
|
- --with-gallium-drivers=svga,r300,r600,radeonsi,nouveau,swrast,virgl \
|
|
+ -Dselinux=false \
|
|
- %{?dri_drivers}
|
|
+ -Dosmesa=gallium \
|
|
-
|
|
+ %{nil}
|
|
-# libtool refuses to pass through things you ask for in LDFLAGS that it doesn't
|
|
+%meson_build
|
|
-# know about, like -static-libstdc++, so...
|
|
|
|
-sed -i 's/-fuse-linker-plugin|/-static-lib*|&/' libtool
|
|
|
|
-sed -i 's/-nostdlib//g' libtool
|
|
|
|
-sed -i 's/^predep_objects=.*$/#&/' libtool
|
|
|
|
-sed -i 's/^postdep_objects=.*$/#&/' libtool
|
|
|
|
-sed -i 's/^postdeps=.*$/#&/' libtool
|
|
|
|
-
|
|
|
|
-make %{?_smp_mflags} MKDEP=/bin/true V=1
|
|
|
|
|
|
|
|
%install
|
|
%install
|
|
rm -rf $RPM_BUILD_ROOT
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
+%meson_install
|
|
|
|
|
|
-# core libs and headers, but not drivers.
|
|
+install glesv2.pc %{buildroot}%{_libdir}/pkgconfig/
|
|
-make install DESTDIR=$RPM_BUILD_ROOT DRI_DIRS=
|
|
+
|
|
|
|
+install egl.pc %{buildroot}%{_libdir}/pkgconfig/
|
|
|
|
|
|
# libvdpau opens the versioned name, don't bother including the unversioned
|
|
# libvdpau opens the versioned name, don't bother including the unversioned
|
|
rm -f %{buildroot}%{_libdir}/vdpau/*.so
|
|
rm -f %{buildroot}%{_libdir}/vdpau/*.so
|
|
@@ -493,19 +509,24 @@ rm -f %{buildroot}%{_libdir}/libGLES*
|
|
# glvnd needs a default provider for indirect rendering where it cannot
|
|
# glvnd needs a default provider for indirect rendering where it cannot
|
|
# determine the vendor
|
|
# determine the vendor
|
|
ln -s %{_libdir}/libGLX_mesa.so.0 %{buildroot}%{_libdir}/libGLX_indirect.so.0
|
|
ln -s %{_libdir}/libGLX_mesa.so.0 %{buildroot}%{_libdir}/libGLX_indirect.so.0
|
|
|
|
+ln -s %{_libdir}/libGLX_mesa.so.0 %{buildroot}%{_libdir}/libGLX_system.so.0
|
|
%endif
|
|
%endif
|
|
|
|
|
|
# strip out useless headers
|
|
# strip out useless headers
|
|
rm -f %{buildroot}%{_includedir}/GL/w*.h
|
|
rm -f %{buildroot}%{_includedir}/GL/w*.h
|
|
|
|
|
|
-# these are shipped already in vulkan-devel
|
|
|
|
-rm -f %{buildroot}/%{_includedir}/vulkan/vk_platform.h
|
|
|
|
-rm -f %{buildroot}/%{_includedir}/vulkan/vulkan.h
|
|
|
|
-
|
|
|
|
pushd $RPM_BUILD_ROOT%{_libdir}
|
|
pushd $RPM_BUILD_ROOT%{_libdir}
|
|
rm -f xorg/modules/drivers/modesetting_drv.so
|
|
rm -f xorg/modules/drivers/modesetting_drv.so
|
|
popd
|
|
popd
|
|
|
|
|
|
|
|
+# this keeps breaking, check it early. note that the exit from eu-ftr is odd.
|
|
|
|
+pushd %{buildroot}%{_libdir}
|
|
|
|
+for i in libOSMesa*.so libGL.so ; do
|
|
|
|
+ eu-findtextrel $i && exit 1
|
|
|
|
+done
|
|
|
|
+popd
|
|
|
|
+
|
|
|
|
+
|
|
# remove .la files
|
|
# remove .la files
|
|
find %{buildroot} -name '*.la' -delete
|
|
find %{buildroot} -name '*.la' -delete
|
|
|
|
|
|
@@ -590,9 +611,10 @@ rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
%files dri-drivers
|
|
%files dri-drivers
|
|
%defattr(-,root,root,-)
|
|
%defattr(-,root,root,-)
|
|
-%config(noreplace) %{_sysconfdir}/drirc
|
|
|
|
%dir %{_libdir}/dri
|
|
%dir %{_libdir}/dri
|
|
%{_libdir}/dri/*_dri.so
|
|
%{_libdir}/dri/*_dri.so
|
|
|
|
+%dir %{_datadir}/drirc.d
|
|
|
|
+%config(noreplace) %{_datadir}/drirc.d/*
|
|
|
|
|
|
%files vdpau-drivers
|
|
%files vdpau-drivers
|
|
%defattr(-,root,root,-)
|
|
%defattr(-,root,root,-)
|
|
@@ -621,8 +643,6 @@ rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
%files libGLES
|
|
%files libGLES
|
|
%defattr(-,root,root,-)
|
|
%defattr(-,root,root,-)
|
|
-%{_libdir}/libGLESv1_CM.so.1
|
|
|
|
-%{_libdir}/libGLESv1_CM.so.1.*
|
|
|
|
%{_libdir}/libGLESv2.so.2
|
|
%{_libdir}/libGLESv2.so.2
|
|
%{_libdir}/libGLESv2.so.2.*
|
|
%{_libdir}/libGLESv2.so.2.*
|
|
%{_libdir}/libglapi.so.0
|
|
%{_libdir}/libglapi.so.0
|
|
@@ -630,11 +650,6 @@ rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
%files libGLES-devel
|
|
%files libGLES-devel
|
|
%defattr(-,root,root,-)
|
|
%defattr(-,root,root,-)
|
|
-%dir %{_includedir}/GLES
|
|
|
|
-%{_includedir}/GLES/egl.h
|
|
|
|
-%{_includedir}/GLES/gl.h
|
|
|
|
-%{_includedir}/GLES/glext.h
|
|
|
|
-%{_includedir}/GLES/glplatform.h
|
|
|
|
%dir %{_includedir}/GLES2
|
|
%dir %{_includedir}/GLES2
|
|
%{_includedir}/GLES2/gl2platform.h
|
|
%{_includedir}/GLES2/gl2platform.h
|
|
%{_includedir}/GLES2/gl2.h
|
|
%{_includedir}/GLES2/gl2.h
|
|
@@ -645,9 +660,7 @@ rm -rf $RPM_BUILD_ROOT
|
|
%{_includedir}/GLES3/gl3ext.h
|
|
%{_includedir}/GLES3/gl3ext.h
|
|
%{_includedir}/GLES3/gl31.h
|
|
%{_includedir}/GLES3/gl31.h
|
|
%{_includedir}/GLES3/gl32.h
|
|
%{_includedir}/GLES3/gl32.h
|
|
-%{_libdir}/pkgconfig/glesv1_cm.pc
|
|
|
|
%{_libdir}/pkgconfig/glesv2.pc
|
|
%{_libdir}/pkgconfig/glesv2.pc
|
|
-%{_libdir}/libGLESv1_CM.so
|
|
|
|
%{_libdir}/libGLESv2.so
|
|
%{_libdir}/libGLESv2.so
|
|
|
|
|
|
%files libOSMesa
|
|
%files libOSMesa
|
|
@@ -689,6 +702,17 @@ rm -rf $RPM_BUILD_ROOT
|
|
%{_includedir}/xa_context.h
|
|
%{_includedir}/xa_context.h
|
|
%{_libdir}/pkgconfig/xatracker.pc
|
|
%{_libdir}/pkgconfig/xatracker.pc
|
|
|
|
|
|
|
|
+%if 0%{?with_nine}
|
|
|
|
+%files libd3d
|
|
|
|
+%dir %{_libdir}/d3d/
|
|
|
|
+%{_libdir}/d3d/*.so.*
|
|
|
|
+
|
|
|
|
+%files libd3d-devel
|
|
|
|
+%{_libdir}/pkgconfig/d3d.pc
|
|
|
|
+%{_includedir}/d3dadapter/
|
|
|
|
+%{_libdir}/d3d/*.so
|
|
|
|
+%endif
|
|
|
|
+
|
|
# We constructed this dir carefully, so just slurp in the whole thing.
|
|
# We constructed this dir carefully, so just slurp in the whole thing.
|
|
%files source
|
|
%files source
|
|
%defattr(-,root,root,-)
|
|
%defattr(-,root,root,-)
|
|
@@ -742,8 +766,6 @@ rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
%files -n compat32-%{name}-libGLES
|
|
%files -n compat32-%{name}-libGLES
|
|
%defattr(-,root,root,-)
|
|
%defattr(-,root,root,-)
|
|
-%{_libdir}/libGLESv1_CM.so.1
|
|
|
|
-%{_libdir}/libGLESv1_CM.so.1.*
|
|
|
|
%{_libdir}/libGLESv2.so.2
|
|
%{_libdir}/libGLESv2.so.2
|
|
%{_libdir}/libGLESv2.so.2.*
|
|
%{_libdir}/libGLESv2.so.2.*
|
|
%{_libdir}/libglapi.so.0
|
|
%{_libdir}/libglapi.so.0
|
|
@@ -751,7 +773,6 @@ rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
%files -n compat32-%{name}-libGLES-devel
|
|
%files -n compat32-%{name}-libGLES-devel
|
|
%defattr(-,root,root,-)
|
|
%defattr(-,root,root,-)
|
|
-%{_libdir}/libGLESv1_CM.so
|
|
|
|
%{_libdir}/libGLESv2.so
|
|
%{_libdir}/libGLESv2.so
|
|
%{_libdir}/libglapi.so
|
|
%{_libdir}/libglapi.so
|
|
|
|
|
|
@@ -777,6 +798,12 @@ rm -rf $RPM_BUILD_ROOT
|
|
%endif
|
|
%endif
|
|
|
|
|
|
%changelog
|
|
%changelog
|
|
|
|
+* Fri Sep 20 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 19.1.7-1
|
|
|
|
+- updated to 19.1.7.
|
|
|
|
+- dropped Patch1.
|
|
|
|
+- imported Patche7 from rawhide.
|
|
|
|
+- switched the build-system to meson.
|
|
|
|
+
|
|
* Wed Dec 05 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 18.2.6-1
|
|
* Wed Dec 05 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 18.2.6-1
|
|
- updated to 18.2.6.
|
|
- updated to 18.2.6.
|
|
- dropped Patch2, 4, 10 and 11.
|
|
- dropped Patch2, 4, 10 and 11.
|