diff --git a/xorg-x11-drv-openchrome.spec b/xorg-x11-drv-openchrome.spec index d0df4fc..1ab006c 100644 --- a/xorg-x11-drv-openchrome.spec +++ b/xorg-x11-drv-openchrome.spec @@ -6,10 +6,16 @@ %define with_xvmc 1 +%ifarch %{ix86} x86_64 +%define with_dri 1 +%else +%define with_dri 0 +%endif + Summary: Xorg X11 openchrome video driver Name: xorg-x11-drv-openchrome Version: 0.2.901 -Release: 6%{?dist} +Release: 2%{?dist} URL: http://www.openchrome.org License: MIT Group: User Interface/X Hardware Support @@ -18,9 +24,8 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Source0: http://www.openchrome.org/releases/%{tarball}-%{version}.tar.bz2 Source1: openchrome.xinf -Patch1: openchrome-0.2.901-libpciaccess.patch -Patch2: openchrome-0.2.901-replace_xf86memcpy.patch -Patch3: openchrome-0.2.901-P4M900_fifo_settings.patch +Patch1: openchrome-0.2.901-P4M900_fifo_settings.patch + ExclusiveArch: %{ix86} x86_64 BuildRequires: pkgconfig @@ -33,12 +38,11 @@ BuildRequires: mesa-libGL-devel %if %{with_xvmc} BuildRequires: libXvMC-devel %endif +%if %{with_dri} BuildRequires: libdrm-devel >= 2.0-1 +%endif Requires: xorg-x11-server-Xorg -Obsoletes: xorg-x11-drv-via -Provides: xorg-x11-drv-via - %description X.Org X11 openchrome video driver. @@ -54,13 +58,15 @@ X.Org X11 openchrome video driver XvMC development package. %prep %setup -q -n %{tarball}-%{version} -%patch1 -p0 -b .libpciaccess -%patch2 -p0 -b .xf86memcpy -%patch3 -p0 -b .P4M900_fifo +%patch1 -p0 -b .P4M900_fifo %build -autoreconf -%configure --disable-static --enable-dri +%configure --disable-static \ +%if %{with_dri} + --enable-dri +%else + --disable-dri +%endif make %install @@ -78,11 +84,6 @@ find $RPM_BUILD_ROOT -regex ".*\.la$" | xargs rm -f -- %clean rm -rf $RPM_BUILD_ROOT -%post -if [ -e /etc/X11/xorg.conf ]; then - sed -i "/Driver/s/via/openchrome/" /etc/X11/xorg.conf || : -fi - %files %defattr(-,root,root,-) %doc release_notes-0.3.0 COPYING @@ -105,33 +106,12 @@ fi %changelog -* Wed Jan 23 2008 Xavier Bachelot - 0.2.901-6 +* Sun Jan 27 2008 Xavier Bachelot - 0.2.901-2 - Add patch to properly set fifo on P4M900. -* Fri Jan 19 2008 Xavier Bachelot - 0.2.901-5 -- Add patch to replace xf86memcpy by plain memcpy. - -* Thu Jan 10 2008 Xavier Bachelot - 0.2.901-4 -- Another try at fixing the libpciaccess patch. - -* Mon Jan 07 2008 Xavier Bachelot - 0.2.901-3 -- And now fix patch filename... - -* Mon Jan 07 2008 Xavier Bachelot - 0.2.901-2 -- Fix broken libpciaccess patch. - * Wed Jan 02 2008 Xavier Bachelot - 0.2.901-1 - Update to 0.2.901. - Remove obsoleted patches. -- Update libpciaccess patch. - -* Fri Dec 08 2007 Xavier Bachelot - 0.2.900-9 -- Add patch for preliminary libpciaccess support. - -* Wed Nov 28 2007 Adam Jackson 0.2.900-8 -- Obsolete xorg-x11-drv-via. The king is dead, long live the king. -- Munge xorg.conf in %%post to change from via to openchrome. -- Drive-by spec cleanups. * Fri Nov 02 2007 Xavier Bachelot - 0.2.900-7 - Replace broken VT1625 NTSC patch.