diff --git a/0001-Switch-to-LoadExtensionList-for-xorg-server-1.16.patch b/0001-Switch-to-LoadExtensionList-for-xorg-server-1.16.patch new file mode 100644 index 0000000..2b0bb3e --- /dev/null +++ b/0001-Switch-to-LoadExtensionList-for-xorg-server-1.16.patch @@ -0,0 +1,25 @@ +From 26a4d5142127c3fe9e4fab32599840103b5615fd Mon Sep 17 00:00:00 2001 +From: Nicolas Chauvet +Date: Mon, 9 Feb 2015 17:22:45 +0100 +Subject: [PATCH] Switch to LoadExtensionList for xorg-server >= 1.16 + +--- + src/x11glvnd/x11glvndserver.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/x11glvnd/x11glvndserver.c b/src/x11glvnd/x11glvndserver.c +index eb06261..c0bb959 100644 +--- a/src/x11glvnd/x11glvndserver.c ++++ b/src/x11glvnd/x11glvndserver.c +@@ -128,7 +128,7 @@ static void *glvSetup(void *module, void *opts, int *errmaj, int *errmin) + return NULL; + } + +- LoadExtension(&glvExtensionModule, False); ++ LoadExtensionList(&glvExtensionModule, 1, False); + + return (pointer)1; + } +-- +2.1.0 + diff --git a/10-x11glvnd.conf b/10-x11glvnd.conf new file mode 100644 index 0000000..ee7b496 --- /dev/null +++ b/10-x11glvnd.conf @@ -0,0 +1,6 @@ +#This file is provided by libglvnd +#Do not edit + +Section "Module" +Load "x11glvnd" +EndSection diff --git a/libglvnd.spec b/libglvnd.spec index 2415e2d..359b548 100644 --- a/libglvnd.spec +++ b/libglvnd.spec @@ -1,15 +1,17 @@ Name: libglvnd -Version: 0 +Version: 0.0.0 Release: 1%{?dist} Summary: The GL Vendor-Neutral Dispatch library License: MIT URL: https://github.com/NVIDIA/libglvnd -Source0: +Source0: libglvnd-%{version}.tar.gz +Source1: 10-x11glvnd.conf +Patch0: 0001-Switch-to-LoadExtensionList-for-xorg-server-1.16.patch BuildRequires: pkgconfig(xorg-server) -BuildRequires: pkgconfig(X11) -BuildRequires: pkgconfig(Xv) +BuildRequires: pkgconfig(x11) +BuildRequires: pkgconfig(xv) %description @@ -21,28 +23,43 @@ Currently, only the GLX window-system API and OpenGL are supported, but in the future this library may support EGL and OpenGL ES as well. -%package devel +%package -n xorg-x11-glvnd Summary: Development files for %{name} Requires: %{name}%{?_isa} = %{version}-%{release} -%description devel +%description -n xorg-x11-glvnd The %{name}-devel package contains libraries and header files for developing applications that use %{name}. %prep %setup -q +#patch0 -p1 -b .orig + + %build -%configure --disable-static -make %{?_smp_mflags} +%configure \ + --disable-static \ + --enable-dt-auxiliary + +make %{?_smp_mflags} V=1 %install -rm -rf $RPM_BUILD_ROOT %make_install -find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';' +find %{buildroot} -name '*.la' -exec rm -f {} ';' + +# Install config file +mkdir -p %{buildroot}%{_datadir}/X11/xorg.conf.d +install -pm 0644 %{SOURCE1} \ + %{buildroot}%{_datadir}/X11/xorg.conf.d + +# Avoid conflict with mesa-libGL for now +mkdir -p %{buildroot}%{_libdir}/%{name} +mv %{buildroot}%{_libdir}/libGL.so* \ + %{buildroot}%{_libdir}/%{name} %post -p /sbin/ldconfig @@ -52,14 +69,15 @@ find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';' %files %doc -%{_libdir}/*.so.* +%{_libdir}/*.so* +%dir %{_libdir}/%{name} +%{_libdir}/%{name}/libGL.so* -%files devel -%doc -%{_includedir}/* -%{_libdir}/*.so +%files -n xorg-x11-glvnd +%{_libdir}/xorg/modules/extensions/*.so* +%{_datadir}/X11/xorg.conf.d/10-x11glvnd.conf %changelog -* Fri Feb 6 2015 -- +* Fri Feb 6 2015 Nicolas Chauvet - 0.0.0-1 +- Initial spec file diff --git a/sources b/sources index e69de29..a2605b2 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +c6b4172e3a134c7e698fc987300701d8 libglvnd-0.0.0.tar.gz