]> git.pld-linux.org Git - packages/Mesa.git/blobdiff - Mesa.spec
- version 6.1, added opt patch, libGLw patch replaced by make overrides
[packages/Mesa.git] / Mesa.spec
index 35cb3f00ec90f6427fae7c52b776a29ad640482f..0c6a47ad2f1f067b637d50d463ce166ac683a525 100644 (file)
--- a/Mesa.spec
+++ b/Mesa.spec
-Summary:       Free OpenGL implementation. Runtime environment
+#
+# Conditional build:
+%bcond_with    glide   # with GLIDE (broken now)
+%bcond_with    xlibs   # use xlibs deps
+#
+Summary:       Free OpenGL implementation
 Summary(pl):   Bezp³atna implementacja standardu OpenGL
 Name:          Mesa
-Version:       3.0
-Release:       6
-Copyright:     GPL
+Version:       6.1
+Release:       1
+License:       MIT (core), LGPL (MesaGLU), SGI (GLU,libGLw) and others - see COPYRIGHT file
 Group:         X11/Libraries
-Group(pl):     X11/Biblioteki
-Source0:       ftp://iris.ssec.wisc.edu/pub/Mesa/%{name}Lib-%{version}.tar.gz
-Source1:       ftp://iris.ssec.wisc.edu/pub/Mesa/%{name}Demos-%{version}.tar.gz
-Patch:         Mesa-misc.diff
+Source0:       http://dl.sourceforge.net/mesa3d/%{name}Lib-%{version}.tar.bz2
+# Source0-md5: 5de1f53ec0709f60fc68fdfed57351f3
+Source1:       http://dl.sourceforge.net/mesa3d/%{name}Demos-%{version}.tar.bz2
+# Source1-md5: 89bfe0f6c69b39fd0ebd9fff481a4e9b
+Patch0:                %{name}-opt.patch
 URL:           http://www.mesa3d.org/
-BuildRoot:     /tmp/%{name}-%{version}-root
+%ifarch %{ix86} alpha
+%{?with_glide:BuildRequires:   Glide3-DRI-devel}
+%{?with_glide:Requires:        Glide3-DRI}
+%endif
+%if %{with xlibs}
+BuildRequires: libXmu-devel
+BuildRequires: libXp-devel
+%else
+BuildRequires: XFree86-devel
+%endif
+BuildRequires: autoconf >= 2.50
+BuildRequires: automake
+BuildRequires: libtool >= 2:1.4d
+BuildRequires: motif-devel
+BuildRequires: perl-devel
+Provides:      OpenGL = 1.5
+Provides:      OpenGL-GLU = 1.3
+# reports version 1.3, but supports glXGetProcAddress() from 1.4
+Provides:      OpenGL-GLX = 1.4
+Obsoletes:     XFree86-OpenGL-libGL
+Obsoletes:     XFree86-OpenGL-libs
+BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+# avoid XFree86-OpenGL* dependency
+# Glide3 can be provided by Glide_V3-DRI or Glide_V5-DRI
+%define                _noautoreqdep   libGL.so.1 libGLU.so.1 libOSMesa.so.4   libglide3.so.3
+
+%define                _sysconfdir     /etc/X11
 
 %description
-Mesa is a 3-D graphics library with an API which is very similar to that
-of OpenGL*.  To the extent that Mesa utilizes the OpenGL command syntax
-or state machine, it is being used with authorization from Silicon Graphics,
-Inc.  However, the author makes no claim that Mesa is in any way a
-compatible replacement for OpenGL or associated with Silicon Graphics, Inc.
-Those who want a licensed implementation of OpenGL should contact a licensed
-vendor.  This software is distributed under the terms of the GNU Library
-General Public License, see the LICENSE file for details.
-
-* OpenGL(R) is a registered trademark of Silicon Graphics, Inc.
+Mesa is a 3-D graphics library with an API which is very similar to
+that of OpenGL*. To the extent that Mesa utilizes the OpenGL command
+syntax or state machine, it is being used with authorization from
+Silicon Graphics, Inc. However, the author makes no claim that Mesa is
+in any way a compatible replacement for OpenGL or associated with
+Silicon Graphics, Inc. Those who want a licensed implementation of
+OpenGL should contact a licensed vendor. This software is distributed
+under the terms of the GNU Library General Public License, see the
+LICENSE file for details.
+
+- OpenGL(R) is a registered trademark of Silicon Graphics, Inc.
 
 %description -l pl
-Mesa jest bibliotek± 3D bêd±c± darmowym odpowiednikiem standartu OpenGL(*).
-* OpenGL jest zastrze¿onym znakiem towarowym firmy Silicon Graphics, Inc.
+Mesa jest bibliotek± 3D bêd±c± darmowym odpowiednikiem standardu
+OpenGL(*).
+
+- OpenGL jest zastrze¿onym znakiem towarowym firmy Silicon Graphics,
+  Inc.
 
 %package devel
 Summary:       Development environment for Mesa
 Summary(pl):   ¦rodowisko programistyczne biblioteki Mesa
 Group:         Development/Libraries
-Group(pl):     Programowanie/Biblioteki
-Requires:      %{name} = %{version}
+Requires:      %{name} = %{version}-%{release}
+%if %{with xlibs}
+Requires:      libX11-devel
+Requires:      libXp-devel
+%else
+Requires:      XFree86-devel
+%endif
+Provides:      OpenGL-devel = 1.5
+Provides:      OpenGL-GLU-devel = 1.3
+Provides:      OpenGL-GLX-devel = 1.4
+Obsoletes:     XFree86-OpenGL-devel
+Obsoletes:     XFree86-OpenGL-devel-base
 
 %description devel
 Header files and documentation needed for development.
 
-%description -l pl devel
+%description devel -l pl
 Pliki nag³ówkowe i dokumentacja do Mesy.
 
 %package static
 Summary:       Mesa static libraries
 Summary(pl):   Biblioteki statyczne Mesy
 Group:         Development/Libraries
-Group(pl):     Programowanie/Biblioteki
-Requires:      %{name}-devel = %{version}
+Requires:      %{name}-devel = %{version}-%{release}
+Provides:      OpenGL-static = 1.5
+Provides:      OpenGL-GLU-static = 1.3
+Obsoletes:     XFree86-OpenGL-static
 
 %description static
-The static version of the Mesa libraries
+The static version of the Mesa libraries.
 
-%description -l pl static
+%description static -l pl
 Biblioteki statyczne Mesy.
 
-%package glut
-Summary:       GLUT library for Mesa
-Summary(pl):   Biblioteka GLUT dla Mesy
-Group:         X11/Libraries
-Group(pl):     X11/Biblioteki
-Requires:      %{name} = %{version}
-Obsoletes:     glut
-
-%description glut
-The GLUT library.
-
-%description -l pl glut
-Biblioteka GLUT
-
-%package glut-devel
-Summary:       GLUT Development environment for Mesa
-Summary(pl):   ¦rodowisko programistyczne 'GLUT' dla biblioteki MESA.
-Group:         Development/Libraries
-Group(pl):     Programowanie/Biblioteki
-Requires:      %{name} = %{version}
-Obsoletes:     glut-devel
-
-%description glut-devel
-Header files needed for development aplications using GLUT library.
-
-%description -l pl glut-devel
-Pliki nag³ówkowe do biblioteki GLUT.
-
-%package glut-static
-Summary:       GLUT static libraries
-Summary(pl):   Biblioteki statyczne do biblioteki GLUT
-Group:         Development/Libraries
-Group(pl):     Programowanie/Biblioteki
-Requires:      %{name}-glut-devel = %{version}
-Obsoletes:     glut-devel
-
-%description glut-static
-The static version of the GLUT library.
-
-%description -l pl glut-static
-Biblioteki statyczne GLUT.
-
 %package demos
 Summary:       Mesa Demos
-Summary(pl):   Demonstracje mo¿liwo¶ci biblioteki MESA.
+Summary(pl):   Demonstracje mo¿liwo¶ci bibliotek Mesa
 Group:         Development/Libraries
-Group(pl):     Programowanie/Biblioteki
-Requires:      %{name} = %{version}
+Requires:      OpenGL-devel
 
 %description demos
 Demonstration programs for the Mesa libraries.
 
-%description -l pl demos
-Programy demonstracyjne dla biblioteki Mesa.
+%description demos -l pl
+Programy demonstracyjne dla bibliotek Mesa.
 
 %prep
 %setup -q -n Mesa-%{version} -b 1
-%patch -p1
+%patch0 -p1
 
-%build
-%ifarch alpha
-make LIBS_ONLY=YES linux-alpha
-make clean
-make linux-alpha-elf
-%endif
+# fix demos
+%{__perl} -pi -e "s,\.\./images/,%{_examplesdir}/Mesa/images/,g" progs/demos/*
 
-%ifarch ppc
-make linux-ppc
-%endif
-
-%ifarch i386
-make clean
-make LIBS_ONLY=YES linux-386
-make clean
-make linux-386-elf
-%endif
-
-%ifarch sparc sparc64
-make  linux-elf
+%build
+%ifarch %{ix86}
+targ=linux-x86
+%else
+targ=linux
 %endif
 
-(cd widgets-mesa; CFLAGS="$RPM_OPT_FLAGS" LDFLAGS="-s" \
-./configure \
-       --prefix=/usr/X11R6/
-make)
+%{__make} ${targ}-static \
+       CC="%{__cc}" \
+       CXX="%{__cxx}" \
+       OPT="%{rpmcflags}" \
+       XLIB_DIR=/usr/X11R6/%{_lib} \
+       GLW_SOURCES="GLwDrawA.c GLwMDrawA.c"
+mv -f lib lib-static
+%{__make} clean
+%{__make} ${targ} \
+       CC="%{__cc}" \
+       CXX="%{__cxx}" \
+       OPT="%{rpmcflags}" \
+       XLIB_DIR=/usr/X11R6/%{_lib}
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT/usr/X11R6/{lib/Mesa,include,man/man3}
-install -d $RPM_BUILD_ROOT/usr/src/examples/Mesa
-
-cp -dpr lib include $RPM_BUILD_ROOT/usr/X11R6
-cp -dpr util $RPM_BUILD_ROOT/usr/X11R6/lib/Mesa
-cp -dpr book demos xdemos samples $RPM_BUILD_ROOT/usr/src/examples/Mesa
-install Make-config $RPM_BUILD_ROOT/usr/X11R6/lib/Mesa
+install -d $RPM_BUILD_ROOT{%{_libdir},%{_includedir}/GL,%{_mandir}/man3,%{_examplesdir}/Mesa}
 
-(cd widgets-mesa; make prefix=$RPM_BUILD_ROOT/usr/X11R6 install )
+cp -df lib-static/lib[GO]* $RPM_BUILD_ROOT%{_libdir}
+cp -df lib/lib[GO]* $RPM_BUILD_ROOT%{_libdir}
+cp -rf include/GL/{gl*,osmesa.h,xmesa*} src/glw/GLw*.h $RPM_BUILD_ROOT%{_includedir}/GL
+rm -f $RPM_BUILD_ROOT%{_includedir}/GL/glut*
 
-install */lib*.a $RPM_BUILD_ROOT/usr/X11R6/lib
+for l in demos redbook samples xdemos ; do
+       %{__make} -C progs/$l clean
+done
+for l in demos redbook samples util xdemos images ; do
+       cp -Rf progs/$l $RPM_BUILD_ROOT%{_examplesdir}/Mesa/$l
+done
+rm -rf $RPM_BUILD_ROOT%{_examplesdir}/Mesa/*/{.deps,CVS,Makefile.{BeOS*,win,cygnus,DJ,dja}}
 
-strip $RPM_BUILD_ROOT/usr/X11R6/lib/{lib*so.*.*,Mesa/*/*} ||
-
-gzip -9nf $RPM_BUILD_ROOT/usr/X11R6/man/man3/* \
-       FUTURE IAFA-PACKAGE LICENSE README* RELNOTES VERSIONS
+%clean
+rm -rf $RPM_BUILD_ROOT
 
 %post   -p /sbin/ldconfig
 %postun -p /sbin/ldconfig
 
-%post   -p /sbin/ldconfig glut
-%postun -p /sbin/ldconfig glut
-
-%clean
-rm -fr $RPM_BUILD_ROOT
-
 %files
 %defattr(644,root,root,755)
-
-%ifnarch ppc
-%attr(755,root,root) /usr/X11R6/lib/libMesa*.so.*.*
-%else
-/usr/X11R6/lib/libMesa*.a
-%endif
-
-%files glut
-%defattr(644,root,root,755)
-%ifnarch ppc
-%attr(755,root,root) /usr/X11R6/lib/libglut.so.*
-%else
-/usr/X11R6/lib/libglut.a
-%endif
-
-%files glut-devel
-%defattr(644,root,root,755)
-/usr/X11R6/include/GL/glut.h
-%ifnarch ppc
-%attr(755,root,root) /usr/X11R6/lib/libglut.so
-%endif
-
-%ifnarch ppc
-%files glut-static
-%defattr(644,root,root,755)
-/usr/X11R6/lib/libglut.a
-%endif
+%doc docs/{*.html,README.{3DFX,GGI,MITS,QUAKE,THREADS,X11},RELNOTES*,VERSIONS}
+%attr(755,root,root) %{_libdir}/libGL.so.*.*
+%attr(755,root,root) %{_libdir}/libGL.so
+%attr(755,root,root) %{_libdir}/libGLU.so.*.*
+%attr(755,root,root) %{_libdir}/libOSMesa.so.*.*
 
 %files devel
 %defattr(644,root,root,755)
-%doc {FUTURE,IAFA-PACKAGE,LICENSE,RELNOTES,VERSIONS,README}.gz
-%doc README.{3DFX,GGI,MGL,QUAKE,VIRGE,X11}.gz
-
-%ifnarch ppc
-%attr(755,root,root) /usr/X11R6/lib/libMesa*.so
-%endif
-
-%dir /usr/X11R6/lib/Mesa
-/usr/X11R6/lib/Mesa/Make-config
-/usr/X11R6/lib/Mesa/util
-
-%dir /usr/X11R6/include/GL
-/usr/X11R6/include/GL/*.h
-/usr/X11R6/man/man3/*
+%doc docs/*.spec
+%attr(755,root,root) %{_libdir}/libGLU.so
+%attr(755,root,root) %{_libdir}/libOSMesa.so
+%{_libdir}/libGLw.a
+%dir %{_includedir}/GL
+%{_includedir}/GL/GLwDrawA.h
+%{_includedir}/GL/GLwDrawAP.h
+%{_includedir}/GL/GLwMDrawA.h
+%{_includedir}/GL/GLwMDrawAP.h
+%{_includedir}/GL/gl.h
+%{_includedir}/GL/glext.h
+%{_includedir}/GL/gl_mangle.h
+%{_includedir}/GL/glu.h
+%{_includedir}/GL/glu_mangle.h
+%{_includedir}/GL/glx.h
+%{_includedir}/GL/glxext.h
+%{_includedir}/GL/glx_mangle.h
+%{_includedir}/GL/osmesa.h
+%{_includedir}/GL/xmesa.h
+%{_includedir}/GL/xmesa_x.h
+%{_includedir}/GL/xmesa_xf86.h
 
-%ifnarch ppc
 %files static
 %defattr(644,root,root,755)
-%endif
-/usr/X11R6/lib/libMesa*.a
+%{_libdir}/libGL.a
+%{_libdir}/libGLU.a
+%{_libdir}/libOSMesa.a
 
 %files demos
 %defattr(644,root,root,755)
-%dir /usr/src/examples/Mesa/book
-%dir /usr/src/examples/Mesa/demos
-%dir /usr/src/examples/Mesa/samples
-%dir /usr/src/examples/Mesa/xdemos
-
-%attr(-,root,root)/usr/src/examples/Mesa/book/*
-%attr(-,root,root)/usr/src/examples/Mesa/demos/*
-%attr(-,root,root)/usr/src/examples/Mesa/samples/*
-%attr(-,root,root)/usr/src/examples/Mesa/xdemos/*
-
-%changelog
-* Mon Mar  8 1999 Tomasz K³oczko <kloczek@rudy.mif.pg.gda.pl>
-  [3.0-4]
-- updated URL to http://www.mesa3d.org/,
-- %doc moved to devel,
-- added static subpackages,
-- removed some README files,
-- removed man group from man pages.
-
-* Tue Feb  9 1999 Micha³ Kuratczyk <kurkens@polbox.com>
-  [3.0-3d]
-- added gzipping documentation
-- simplification in %files
-- fixed pl translations
-
-* Sat Jan 30 1999 Tomasz K³oczko <kloczek@rudy.mif.pg.gda.pl>
-  [3.0-2d]
-- added LDFLAGS="-s" to ./configure enviroment,
-- fixed permission on lib*so* files (must be 755),
-- removed RPM_OPT_FLAGS="$RPM_OPT_FLAGS" make parameters
-  (this is redundant).
-
-* Sat Jan 23 1999 Wojciech "Sas" Cieciwa <cieciwa@alpha.zarz.agh.edu.pl>
-- gzipped man page.
-
-* Thu Jan 12 1999 Wojciech "Sas" Cieciwa <cieciwa@alpha.zarz.agh.edu.pl>
-- fixing library location.
-
-* Thu Oct  1 1998 Wojciech "Sas" Cieciwa <cieciwa@alpha.zarz.agh.edu.pl>
-  [3.0-1]
-- fixing access permision.
-
-* Wed May  5 1998 Tomasz K³oczko <kloczek@rudy.mif.pg.gda.pl>
-- removed declarate %%{version}, %%{name}, %%{release} macros because
-  all are predefined,
-- removed check $RPM_BUILD_ROOT in %clean and %install,
-- added "Requires: Mesa = %%{version}" for all subpackages (for
-  keeping corectly dependences),
-- in Mesa-glut* packages changed "Conflict:" to "Obsoletes:",
-- added striping shared libs and demos,
-- added modification in %build wihch allow build Mesa on sparc[64]
-  architecture,
-- all utils and demos instaled in /usr/lib/Mesa,
-- added %defattr macros in %files (on rebuild require rpm >= 2.4.99),
-- added -q %setup parameter.
-
-* Thu Feb 12 1998 Christian 'Dr. Disk' Hechelmann <drdisk@ds9.au.s.shuttle.de>
-- updated to final version 2.6
-
-* Thu Feb 05 1998 Christian 'Dr. Disk' Hechelmann <drdisk@ds9.au.s.shuttle.de>
-- Fixed thinko in misc patch
-- build against glibc
-
-* Sat Jan 31 1998 Christian 'Dr. Disk' Hechelmann <drdisk@ds9.au.s.shuttle.de>
-- updated to version 2.6beta5
-- added widget-mesa to the things to be build.
-
-* Mon Jan 26 1998 Christian 'Dr. Disk' Hechelmann <drdisk@ds9.au.s.shuttle.de>
-- updated to version 2.6beta4
-
-* Sun Dec 14 1997 Christian 'Dr. Disk' Hechelmann <drdisk@ds9.au.s.shuttle.de>
-- updated to version 2.6beta1
-
-* Sat Dec 13 1997 Christian 'Dr. Disk' Hechelmann <drdisk@ds9.au.s.shuttle.de>
-- Moved GLUT into a separate subpackage and added an Obsoletes tag to this
-  subpackage
-- Moved lib*.so to the devel package, they are only needed for development,
-  not for a runtime environment.
-
-* Sat Nov 29 1997 Christian 'Dr. Disk' Hechelmann <drdisk@ds9.au.s.shuttle.de>
-- added patches from ftp://iris.ssec.wisc.edu/pub/Mesa/patches_to_2.5
-- BuildRoot'ed
-- Prefix'ed
-- added static versions of the libraries. (PPC version seems not to have
-  support for shared versions of the library)
-- moved static versions of the library and the includes to the new subpackage
-  'devel'
-- targets other than linux-x86 still untested.
-- added Conflitcs tag
-- added %postun
-- added patch for RPM_OPT_FLAGS support
-
-* Fri Nov 21 1997 Karsten Weiss <karsten@addx.au.s.shuttle.de>
-- Upgraded to Mesa 2.5
-- Multiarch destinations (untested).
-- Included GLUT.
-- Removed some of the READMEs for other platforms from the binary RPM.
+%{_examplesdir}/Mesa
This page took 0.060514 seconds and 4 git commands to generate.