Browse Source

mesa package update

Signed-off-by: guibuilder_pel7x64builder0 <guibuilder@powerel.org>
master
guibuilder_pel7x64builder0 6 years ago
parent
commit
9ac588a6a8
  1. 29
      SOURCES/0001-pkgconfig-Fix-gl.pc-when-glvnd-is-enabled.patch
  2. 1690
      SOURCES/dri-sw-xshm-support.patch
  3. 39
      SOURCES/fix-timeout-warnings.patch
  4. 47
      SOURCES/make-git-snapshot.sh
  5. 123
      SPECS/mesa.spec

29
SOURCES/0001-pkgconfig-Fix-gl.pc-when-glvnd-is-enabled.patch

@ -0,0 +1,29 @@
From 7c137cfbffb4962b4e080052ef05cfb2266e758a Mon Sep 17 00:00:00 2001
From: Adam Jackson <ajax@redhat.com>
Date: Tue, 29 May 2018 09:47:35 -0400
Subject: [PATCH] pkgconfig: Fix gl.pc when glvnd is enabled

GL_LIB expands to GLX_mesa, but applications should not link against
that. -lGL is never wrong, just hardcode it.

Signed-off-by: Adam Jackson <ajax@redhat.com>
---
src/mesa/gl.pc.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/gl.pc.in b/src/mesa/gl.pc.in
index 181724b97b..8c7b7da8d7 100644
--- a/src/mesa/gl.pc.in
+++ b/src/mesa/gl.pc.in
@@ -7,7 +7,7 @@ Name: gl
Description: Mesa OpenGL library
Requires.private: @GL_PC_REQ_PRIV@
Version: @PACKAGE_VERSION@
-Libs: -L${libdir} -l@GL_LIB@
+Libs: -L${libdir} -lGL
Libs.private: @GL_PC_LIB_PRIV@
Cflags: -I${includedir} @GL_PC_CFLAGS@
glx_tls: @GLX_TLS@
--
2.17.0

1690
SOURCES/dri-sw-xshm-support.patch

File diff suppressed because it is too large Load Diff

39
SOURCES/fix-timeout-warnings.patch

@ -0,0 +1,39 @@
diff -up mesa-20180530/src/gallium/drivers/r600/Makefile.am.dma mesa-20180530/src/gallium/drivers/r600/Makefile.am
--- mesa-20180530/src/gallium/drivers/r600/Makefile.am.dma 2018-07-19 10:24:26.110829986 +1000
+++ mesa-20180530/src/gallium/drivers/r600/Makefile.am 2018-07-19 10:24:44.569297131 +1000
@@ -10,7 +10,8 @@ AM_CFLAGS = \
$(GALLIUM_DRIVER_CFLAGS) \
$(RADEON_CFLAGS) \
$(LIBELF_CFLAGS) \
- -I$(top_srcdir)/src/amd/common
+ -I$(top_srcdir)/src/amd/common \
+ -Wstrict-overflow=0
AM_CXXFLAGS = \
$(GALLIUM_DRIVER_CXXFLAGS) \
diff -up mesa-20180530/src/gallium/winsys/virgl/drm/Makefile.am.dma mesa-20180530/src/gallium/winsys/virgl/drm/Makefile.am
--- mesa-20180530/src/gallium/winsys/virgl/drm/Makefile.am.dma 2018-07-19 10:25:13.089018307 +1000
+++ mesa-20180530/src/gallium/winsys/virgl/drm/Makefile.am 2018-07-19 10:25:34.775566694 +1000
@@ -26,7 +26,8 @@ include $(top_srcdir)/src/gallium/Automa
AM_CFLAGS = \
-I$(top_srcdir)/src/gallium/drivers \
$(GALLIUM_WINSYS_CFLAGS) \
- $(LIBDRM_CFLAGS)
+ $(LIBDRM_CFLAGS) \
+ -Wstrict-overflow=0
noinst_LTLIBRARIES = libvirgldrm.la
diff -up mesa-20180530/src/gallium/winsys/virgl/vtest/Makefile.am.dma mesa-20180530/src/gallium/winsys/virgl/vtest/Makefile.am
--- mesa-20180530/src/gallium/winsys/virgl/vtest/Makefile.am.dma 2018-07-19 10:25:48.521914297 +1000
+++ mesa-20180530/src/gallium/winsys/virgl/vtest/Makefile.am 2018-07-19 10:26:05.622346714 +1000
@@ -25,7 +25,8 @@ include $(top_srcdir)/src/gallium/Automa
AM_CFLAGS = \
-I$(top_srcdir)/src/gallium/drivers \
- $(GALLIUM_WINSYS_CFLAGS)
+ $(GALLIUM_WINSYS_CFLAGS) \
+ -Wstrict-overflow=0
noinst_LTLIBRARIES = libvirglvtest.la

47
SOURCES/make-git-snapshot.sh

@ -1,31 +1,28 @@
#!/bin/sh #!/bin/sh


proto=$1 # Usage: ./make-git-snapshot.sh [COMMIT]
branch=$2 #
# to make a snapshot of the given tag/branch. Defaults to HEAD.
# Point env var REF to a local mesa repo to reduce clone time.


if [ -z "$proto" ]; then if [ -e /usr/bin/pxz ]; then
echo "Usage: $0 <proto name> [<branch>]" XZ=/usr/bin/pxz
exit 1 else
XZ=/usr/bin/xz
fi fi


dirname=$proto-$( date +%Y%m%d ) DIRNAME=mesa-$( date +%Y%m%d )


rm -rf $dirname echo REF ${REF:+--reference $REF}
git clone git://git.freedesktop.org/git/xorg/proto/$proto $dirname echo DIRNAME $DIRNAME
cd $dirname echo HEAD ${1:-18.0}
if [ -z "$branch" ]; then
git log | head -1 rm -rf $DIRNAME
else
git checkout $branch git clone --depth 1 ${REF:+--reference $REF} --branch 18.0 \
fi git://git.freedesktop.org/git/mesa/mesa $DIRNAME
sha=`git rev-list --max-count=1 --abbrev-commit HEAD`
git repack -a -d GIT_DIR=$DIRNAME/.git git archive --format=tar --prefix=$DIRNAME/ ${1:-HEAD} \
cd .. | $XZ > $DIRNAME.tar.xz


# append sha to dirname # rm -rf $DIRNAME
mv $dirname $dirname-git$sha
dirname=$dirname-git$sha
tarball=$dirname.tar.bz2
tar jcf $tarball $dirname
rm -rf $dirname
echo "$tarball is now available"

123
SPECS/mesa.spec

@ -55,19 +55,19 @@


%define _default_patch_fuzz 2 %define _default_patch_fuzz 2


%define gitdate 20171019 #define gitdate 20180530
#% define snapshot #% define snapshot


Summary: Mesa graphics libraries Summary: Mesa graphics libraries
Name: mesa Name: mesa
Version: 17.2.3 Version: 18.0.5
Release: 8.%{gitdate}%{?dist} Release: 3%{?dist}
License: MIT License: MIT
Group: System Environment/Libraries Group: System Environment/Libraries
URL: http://www.mesa3d.org URL: http://www.mesa3d.org


# Source0: MesaLib-%{version}.tar.xz Source0: mesa-%{version}.tar.xz
Source0: %{name}-%{gitdate}.tar.xz #Source0: %{name}-%{gitdate}.tar.xz
Source1: sanitize-tarball.sh Source1: sanitize-tarball.sh
Source2: make-release-tarball.sh Source2: make-release-tarball.sh
Source3: make-git-snapshot.sh Source3: make-git-snapshot.sh
@ -77,23 +77,16 @@ Source3: make-git-snapshot.sh
# 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


Patch0: mesa-17.3-final.patch
Patch1: nv50-fix-build.patch Patch1: nv50-fix-build.patch
Patch2: 0001-mesa-Squash-merge-of-S3TC-support.patch # backport of dri sw xshm support to help qxl
Patch9: mesa-8.0-llvmpipe-shmget.patch Patch2: dri-sw-xshm-support.patch

# fix some timeout mismatch warnings (backport from upstream)
Patch3: fix-timeout-warnings.patch
Patch12: mesa-8.0.1-fix-16bpp.patch Patch12: mesa-8.0.1-fix-16bpp.patch
Patch15: mesa-9.2-hardware-float.patch Patch15: mesa-9.2-hardware-float.patch
Patch20: mesa-10.2-evergreen-big-endian.patch Patch20: mesa-10.2-evergreen-big-endian.patch

Patch21: 0001-pkgconfig-Fix-gl.pc-when-glvnd-is-enabled.patch
# For bz1503861, fix visual artifacts on DRI PRIME offloading
# Feel free to drop these patches during the next mesa rebase (>17.2.3)
Patch30: 0001-intel-blorp-Use-mocs.tex-for-depth-stencil.patch
Patch31: 0002-anv-blorp-Add-a-device-parameter-to-blorp_surf_for_a.patch
Patch32: 0003-blorp-Turn-anv_CmdCopyBuffer-into-a-blorp_buffer_cop.patch
Patch33: 0004-intel-blorp-Make-the-MOCS-setting-part-of-blorp_addr.patch
Patch34: 0005-i965-Use-PTE-MOCS-for-all-external-buffers.patch

Patch40: 0001-intel-Add-more-Coffee-Lake-PCI-IDs.patch


BuildRequires: pkgconfig autoconf automake libtool BuildRequires: pkgconfig autoconf automake libtool
%if %{with_hardware} %if %{with_hardware}
@ -119,7 +112,7 @@ BuildRequires: python-mako
BuildRequires: gettext BuildRequires: gettext
%if 0%{?with_llvm} %if 0%{?with_llvm}
%if 0%{?with_private_llvm} %if 0%{?with_private_llvm}
BuildRequires: llvm-private-devel >= 5.0 BuildRequires: llvm-private-devel >= 6.0
%else %else
BuildRequires: llvm-devel >= 3.0 BuildRequires: llvm-devel >= 3.0
%endif %endif
@ -133,11 +126,12 @@ BuildRequires: pkgconfig(wayland-client) >= 1.11
BuildRequires: pkgconfig(wayland-server) >= 1.11 BuildRequires: pkgconfig(wayland-server) >= 1.11
BuildRequires: pkgconfig(wayland-protocols) >= 1.8.0 BuildRequires: pkgconfig(wayland-protocols) >= 1.8.0
%endif %endif
BuildRequires: mesa-libGL-devel # BuildRequires: mesa-libGL-devel
%if 0%{?with_vdpau} %if 0%{?with_vdpau}
BuildRequires: libvdpau-devel BuildRequires: libvdpau-devel
%endif %endif
BuildRequires: zlib-devel BuildRequires: zlib-devel
BuildRequires: libglvnd-devel


%description %description
Mesa Mesa
@ -148,6 +142,7 @@ Group: System Environment/Libraries
Provides: libGL Provides: libGL
Requires: mesa-libglapi = %{version}-%{release} Requires: mesa-libglapi = %{version}-%{release}
Requires: libdrm >= 2.4.83 Requires: libdrm >= 2.4.83
Requires: libglvnd-glx%{?_isa} >= 1:1.0.1-0.7


%description libGL %description libGL
Mesa libGL runtime library. Mesa libGL runtime library.
@ -156,6 +151,7 @@ Mesa libGL runtime library.
Summary: Mesa libEGL runtime libraries Summary: Mesa libEGL runtime libraries
Group: System Environment/Libraries Group: System Environment/Libraries
Requires: mesa-libgbm = %{version}-%{release} Requires: mesa-libgbm = %{version}-%{release}
Requires: libglvnd-egl%{?_isa}


%description libEGL %description libEGL
Mesa libEGL runtime libraries Mesa libEGL runtime libraries
@ -164,6 +160,7 @@ Mesa libEGL runtime libraries
Summary: Mesa libGLES runtime libraries Summary: Mesa libGLES runtime libraries
Group: System Environment/Libraries Group: System Environment/Libraries
Requires: mesa-libglapi = %{version}-%{release} Requires: mesa-libglapi = %{version}-%{release}
Requires: libglvnd-gles%{?_isa}


%description libGLES %description libGLES
Mesa GLES runtime libraries Mesa GLES runtime libraries
@ -200,6 +197,7 @@ Summary: Mesa libGL development package
Group: Development/Libraries Group: Development/Libraries
Requires: mesa-libGL = %{version}-%{release} Requires: mesa-libGL = %{version}-%{release}
Requires: gl-manpages Requires: gl-manpages
Requires: libglvnd-devel%{?_isa}
Provides: libGL-devel Provides: libGL-devel


%description libGL-devel %description libGL-devel
@ -209,6 +207,7 @@ Mesa libGL development package
Summary: Mesa libEGL development package Summary: Mesa libEGL development package
Group: Development/Libraries Group: Development/Libraries
Requires: mesa-libEGL = %{version}-%{release} Requires: mesa-libEGL = %{version}-%{release}
Requires: libglvnd-devel%{?_isa}
Provides: khrplatform-devel = %{version}-%{release} Provides: khrplatform-devel = %{version}-%{release}
Obsoletes: khrplatform-devel < %{version}-%{release} Obsoletes: khrplatform-devel < %{version}-%{release}


@ -219,6 +218,7 @@ Mesa libEGL development package
Summary: Mesa libGLES development package Summary: Mesa libGLES development package
Group: Development/Libraries Group: Development/Libraries
Requires: mesa-libGLES = %{version}-%{release} Requires: mesa-libGLES = %{version}-%{release}
Requires: libglvnd-devel%{?_isa}


%description libGLES-devel %description libGLES-devel
Mesa libGLES development package Mesa libGLES development package
@ -321,35 +321,19 @@ The drivers with support for the Vulkan API.
%endif %endif


%prep %prep
#setup -q -n Mesa-%{version}%{?snapshot} %setup -q -n mesa-%{version}%{?snapshot}
%setup -q -n mesa-%{gitdate} #setup -q -n mesa-%{gitdate}
# make sure you run sanitize-tarball.sh on mesa source tarball or next line will exit # make sure you run sanitize-tarball.sh on mesa source tarball or next line will exit
grep -q ^/ src/gallium/auxiliary/vl/vl_decoder.c && exit 1 grep -q ^/ src/gallium/auxiliary/vl/vl_decoder.c && exit 1
%patch0 -p1 -b .mesa17.2.3
%patch1 -p1 -b .nv50rtti %patch1 -p1 -b .nv50rtti
%patch2 -p1 -b .s3tc %patch2 -p1 -b .xshm

%patch3 -p1 -b .timeout
# this fastpath is:
# - broken with swrast classic
# - broken on 24bpp
# - not a huge win anyway
# - ABI-broken wrt upstream
# - eventually obsoleted by vgem
#
# dear ajax: fix this one way or the other
#patch9 -p1 -b .shmget
#patch12 -p1 -b .16bpp #patch12 -p1 -b .16bpp


%patch15 -p1 -b .hwfloat %patch15 -p1 -b .hwfloat
#patch20 -p1 -b .egbe #patch20 -p1 -b .egbe

%patch21 -p1 -b .glpc
%patch30 -p1 -b .bz1503861_patch1
%patch31 -p1 -b .bz1503861_patch2
%patch32 -p1 -b .bz1503861_patch3
%patch33 -p1 -b .bz1503861_patch4
%patch34 -p1 -b .bz1503861_patch5

%patch40 -p1 -b .cfl_ids


%if 0%{with_private_llvm} %if 0%{with_private_llvm}
sed -i 's/\[llvm-config\]/\[llvm-private-config-%{__isa_bits}\]/g' configure.ac sed -i 's/\[llvm-config\]/\[llvm-private-config-%{__isa_bits}\]/g' configure.ac
@ -383,6 +367,7 @@ export CXXFLAGS="$RPM_OPT_FLAGS -fno-rtti -fno-exceptions"


%configure \ %configure \
%{?asm_flags} \ %{?asm_flags} \
--enable-libglvnd \
--enable-selinux \ --enable-selinux \
--enable-osmesa \ --enable-osmesa \
--with-dri-driverdir=%{_libdir}/dri \ --with-dri-driverdir=%{_libdir}/dri \
@ -410,9 +395,6 @@ export CXXFLAGS="$RPM_OPT_FLAGS -fno-rtti -fno-exceptions"
%endif %endif
%{?dri_drivers} %{?dri_drivers}


# this seems to be neccessary for s390
make -C src/mesa/drivers/dri/common/xmlpool/

make %{?_smp_mflags} MKDEP=/bin/true make %{?_smp_mflags} MKDEP=/bin/true


%install %install
@ -433,6 +415,17 @@ rm -f $RPM_BUILD_ROOT%{_sysconfdir}/drirc


# libvdpau opens the versioned name, don't bother including the unversioned # libvdpau opens the versioned name, don't bother including the unversioned
rm -f $RPM_BUILD_ROOT%{_libdir}/vdpau/*.so rm -f $RPM_BUILD_ROOT%{_libdir}/vdpau/*.so
# likewise glvnd
rm -f %{buildroot}%{_libdir}/libGLX_mesa.so
rm -f %{buildroot}%{_libdir}/libEGL_mesa.so
# XXX can we just not build this
rm -f %{buildroot}%{_libdir}/libGLES*

# XXX wayland-egl?

# glvnd needs a default provider for indirect rendering where it cannot
# determine the vendor
ln -s %{_libdir}/libGLX_mesa.so.0 %{buildroot}%{_libdir}/libGLX_system.so.0


# strip out useless headers # strip out useless headers
rm -f $RPM_BUILD_ROOT%{_includedir}/GL/w*.h rm -f $RPM_BUILD_ROOT%{_includedir}/GL/w*.h
@ -479,18 +472,17 @@ rm -rf $RPM_BUILD_ROOT


%files libGL %files libGL
%defattr(-,root,root,-) %defattr(-,root,root,-)
%{_libdir}/libGL.so.1 %{_libdir}/libGLX_mesa.so.0*
%{_libdir}/libGL.so.1.* %{_libdir}/libGLX_system.so.0*


%files libEGL %files libEGL
%defattr(-,root,root,-) %defattr(-,root,root,-)
%{_libdir}/libEGL.so.1 %{_datadir}/glvnd/egl_vendor.d/50_mesa.json
%{_libdir}/libEGL.so.1.* %{_libdir}/libEGL_mesa.so.0*


%files libGLES %files libGLES
%defattr(-,root,root,-) %defattr(-,root,root,-)
%{_libdir}/libGLESv2.so.2 # no files, all provided by libglvnd
%{_libdir}/libGLESv2.so.2.*


%files filesystem %files filesystem
%defattr(-,root,root,-) %defattr(-,root,root,-)
@ -569,7 +561,6 @@ rm -rf $RPM_BUILD_ROOT
%dir %{_includedir}/GL/internal %dir %{_includedir}/GL/internal
%{_includedir}/GL/internal/dri_interface.h %{_includedir}/GL/internal/dri_interface.h
%{_libdir}/pkgconfig/dri.pc %{_libdir}/pkgconfig/dri.pc
%{_libdir}/libGL.so
%{_libdir}/libglapi.so %{_libdir}/libglapi.so
%{_libdir}/pkgconfig/gl.pc %{_libdir}/pkgconfig/gl.pc


@ -584,7 +575,6 @@ rm -rf $RPM_BUILD_ROOT
%dir %{_includedir}/KHR %dir %{_includedir}/KHR
%{_includedir}/KHR/khrplatform.h %{_includedir}/KHR/khrplatform.h
%{_libdir}/pkgconfig/egl.pc %{_libdir}/pkgconfig/egl.pc
%{_libdir}/libEGL.so


%files libGLES-devel %files libGLES-devel
%defattr(-,root,root,-) %defattr(-,root,root,-)
@ -599,7 +589,6 @@ rm -rf $RPM_BUILD_ROOT
%{_includedir}/GLES3/gl32.h %{_includedir}/GLES3/gl32.h
%{_includedir}/GLES3/gl3ext.h %{_includedir}/GLES3/gl3ext.h
%{_libdir}/pkgconfig/glesv2.pc %{_libdir}/pkgconfig/glesv2.pc
%{_libdir}/libGLESv2.so


%files libOSMesa %files libOSMesa
%defattr(-,root,root,-) %defattr(-,root,root,-)
@ -670,6 +659,32 @@ rm -rf $RPM_BUILD_ROOT
%endif %endif


%changelog %changelog
* Tue Jul 24 2018 Dave Airlie <airlied@redhat.com> - 18.0.5-3
- rename fedora to system in glvnd fallback

* Thu Jul 19 2018 Dave Airlie <airlied@redhat.com> - 18.0.5-2
- Fix timeout overflow warnings (backport from upstream + virgl)

* Wed Jun 20 2018 Adam Jackson <ajax@redhat.com> - 18.0.5-1
- Mesa 18.0.5

* Wed May 30 2018 Dave Airlie <airlied@redhat.com - 18.0.4-1.20180530
- rebase to 18.0.4
- backport shm put/get image for improved sw renderers (esp under qxl)

* Tue May 29 2018 Adam Jackson <ajax@redhat.com> - 18.0.3-5.20180508
- Fix gl.pc when using glvnd
- Fix subpackage dependencies for glvnd

* Fri May 25 2018 Adam Jackson <ajax@redhat.com> - 18.0.3-2.20180508
- Use glvnd

* Tue May 08 2018 Dave Airlie <airlied@redhat.com> 18.0.3-1.20180508
- rebase to 18.0.3

* Wed Apr 18 2018 Adam Jackson <ajax@redhat.com> - 17.2.3-9
- Rebuild for new llvm

* Mon Jan 15 2018 Dave Airlie <airlied@redhat.com> - 17.2.3-8.20171019 * Mon Jan 15 2018 Dave Airlie <airlied@redhat.com> - 17.2.3-8.20171019
- Add missing Intel CFL ids. - Add missing Intel CFL ids.



Loading…
Cancel
Save