]> git.pld-linux.org Git - packages/Mesa.git/blob - Mesa.spec
- removed two lines with define
[packages/Mesa.git] / Mesa.spec
1 #
2 # _with_glide: with GLIDE
3 #
4 Summary:        Free OpenGL implementation
5 Summary(pl):    Bezp³atna implementacja standardu OpenGL
6 Name:           Mesa
7 Version:        5.0
8 Release:        1
9 License:        MIT (core), LGPL (MesaGLU), SGI (GLU,libGLw) and others - see COPYRIGHT file
10 Group:          X11/Libraries
11 Source0:        ftp://ftp.sourceforge.net/pub/sourceforge/mesa3d/%{name}Lib-%{version}.tar.bz2
12 Source1:        ftp://ftp.sourceforge.net/pub/sourceforge/mesa3d/%{name}Demos-%{version}.tar.bz2
13 Patch0:         %{name}-am.patch
14 Patch1:         %{name}-ac.patch
15 Patch2:         %{name}-libGLw.patch
16 URL:            http://www.mesa3d.org/
17 BuildRequires:  XFree86-devel
18 BuildRequires:  autoconf
19 BuildRequires:  motif-devel
20 BuildRequires:  perl
21 %ifarch %{ix86} alpha
22 %{?_with_glide:BuildRequires:   Glide3-DRI-devel}
23 %{?_with_glide:Requires:        Glide3-DRI}
24 %endif
25 Provides:       OpenGL
26 Obsoletes:      XFree86-OpenGL-core XFree86-OpenGL-libs
27 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
28
29 # avoid XFree86-OpenGL* dependency
30 # Glide3 can be provided by Glide_V3-DRI or Glide_V5-DRI
31 %define         _noautoreqdep   libGL.so.1 libGLU.so.1 libOSMesa.so.4   libglide3.so.3
32
33 %define         _sysconfdir     /etc/X11
34
35 %description
36 Mesa is a 3-D graphics library with an API which is very similar to
37 that of OpenGL*. To the extent that Mesa utilizes the OpenGL command
38 syntax or state machine, it is being used with authorization from
39 Silicon Graphics, Inc. However, the author makes no claim that Mesa is
40 in any way a compatible replacement for OpenGL or associated with
41 Silicon Graphics, Inc. Those who want a licensed implementation of
42 OpenGL should contact a licensed vendor. This software is distributed
43 under the terms of the GNU Library General Public License, see the
44 LICENSE file for details.
45
46 - OpenGL(R) is a registered trademark of Silicon Graphics, Inc.
47
48 %description -l pl
49 Mesa jest bibliotek± 3D bêd±c± darmowym odpowiednikiem standardu
50 OpenGL(*).
51
52 - OpenGL jest zastrze¿onym znakiem towarowym firmy Silicon Graphics,
53   Inc.
54
55 %package devel
56 Summary:        Development environment for Mesa
57 Summary(pl):    ¦rodowisko programistyczne biblioteki Mesa
58 Group:          Development/Libraries
59 Requires:       %{name} = %{version}
60 Requires:       XFree86-devel
61 Provides:       OpenGL-devel
62 Obsoletes:      XFree86-OpenGL-devel
63
64 %description devel
65 Header files and documentation needed for development.
66
67 %description devel -l pl
68 Pliki nag³ówkowe i dokumentacja do Mesy.
69
70 %package static
71 Summary:        Mesa static libraries
72 Summary(pl):    Biblioteki statyczne Mesy
73 Group:          Development/Libraries
74 Requires:       %{name}-devel = %{version}
75 Provides:       OpenGL-static
76 Obsoletes:      XFree86-OpenGL-static
77
78 %description static
79 The static version of the Mesa libraries.
80
81 %description static -l pl
82 Biblioteki statyczne Mesy.
83
84 %package demos
85 Summary:        Mesa Demos
86 Summary(pl):    Demonstracje mo¿liwo¶ci bibliotek Mesa
87 Group:          Development/Libraries
88 Requires:       OpenGL-devel
89
90 %description demos
91 Demonstration programs for the Mesa libraries.
92
93 %description demos -l pl
94 Programy demonstracyjne dla bibliotek Mesa.
95
96 %prep
97 %setup -q -n Mesa-%{version} -b 1
98 %patch0 -p1
99 %patch1 -p1
100 %patch2 -p1
101
102 # fix demos
103 perl -pi -e "s,\.\./images/,%{_examplesdir}/Mesa/images/,g" demos/*
104
105 %build
106 %configure \
107         --enable-static \
108         --enable-shared \
109         --with-ggi="no" \
110         --with-svga="no" \
111         --disable-ggi-fbdev \
112         --disable-ggi-genkgi \
113         --enable-optimize \
114         %{!?_with_glide:--without-glide} \
115 %ifarch %{ix86} \
116         --enable-x86 \
117   %ifarch i586 i686 k6 athlon \
118         --enable-mmx \
119         --enable-3dnow \
120     %ifarch i686 athlon \
121         --enable-katmai \
122     %else \
123         --disable-katmai \
124     %endif \
125   %else \
126         --disable-mmx \
127         --disable-3dnow \
128   %endif \
129 %else \
130 %ifarch sparc \
131         --enable-sparc \
132 %endif \
133         --disable-x86 \
134         --disable-mmx \
135         --disable-3dnow
136 %endif
137
138 %{__make}
139         
140 cd widgets-mesa
141 %{__autoconf}
142 %configure \
143         --with-motif
144 %{__make} || :
145 cd ../widgets-sgi
146 touch depend
147 %{__make} dep
148 %{__make} linux OPTFLAGS="%{rpmcflags}"
149 cd ..
150
151 %install
152 rm -rf $RPM_BUILD_ROOT
153 %{__make} install DESTDIR=$RPM_BUILD_ROOT
154
155 install -d $RPM_BUILD_ROOT%{_mandir}/man3
156
157 SPWD=`pwd`
158 cd widgets-mesa
159 %{__make} install \
160         prefix=$RPM_BUILD_ROOT%{_prefix} \
161         mandir=$RPM_BUILD_ROOT%{_mandir}/man3
162 # Mesa widgets are not binary compatible with SGI ones
163 cd $RPM_BUILD_ROOT%{_includedir}/GL
164 mkdir Mesa-widgets
165 mv -f GLw*.h Mesa*.h Mesa-widgets
166 cd $SPWD
167
168 install widgets-sgi/libGLw* $RPM_BUILD_ROOT%{_libdir}
169 install widgets-sgi/GLw*.h $RPM_BUILD_ROOT%{_includedir}/GL
170
171 install -d $RPM_BUILD_ROOT/usr/src/examples/Mesa
172 for l in book demos samples xdemos images ; do
173         cp -Rf $l $RPM_BUILD_ROOT%{_examplesdir}/Mesa/$l
174 done
175 rm -rf $RPM_BUILD_ROOT%{_examplesdir}/Mesa/*/{.deps,CVS,Makefile.{BeOS*,win,cygnus,DJ,dja}}
176
177 rm -f docs/*~
178
179 %clean
180 rm -rf $RPM_BUILD_ROOT
181
182 %post   -p /sbin/ldconfig
183 %postun -p /sbin/ldconfig
184
185 %files
186 %defattr(644,root,root,755)
187 %doc docs/{CONFORM,COPYRIGHT,README,README.{3DFX,GGI,MITS,QUAKE,THREADS,X11},RELNOTES*,VERSIONS}
188 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mesa.conf
189 %attr(755,root,root) %{_libdir}/libGL*.so.*.*
190 %attr(755,root,root) %{_libdir}/libGL.so
191 %attr(755,root,root) %{_libdir}/libOSMesa.so.*.*
192
193 %files devel
194 %defattr(644,root,root,755)
195 %doc docs/{DEVINFO,*.spec}
196 %{_libdir}/libGL.la
197 %attr(755,root,root) %{_libdir}/libGLU.so
198 %{_libdir}/libGLU.la
199 %attr(755,root,root) %{_libdir}/libOSMesa.so
200 %{_libdir}/libOSMesa.la
201 %{_libdir}/libGLw.a
202 %{_libdir}/libMesaGLw*.a
203 %dir %{_includedir}/GL
204 %{_includedir}/GL/Mesa-widgets
205 %{_includedir}/GL/GLwDrawA.h
206 %{_includedir}/GL/GLwDrawAP.h
207 %{_includedir}/GL/GLwMDrawA.h
208 %{_includedir}/GL/GLwMDrawAP.h
209 %{_includedir}/GL/gl.h
210 %{_includedir}/GL/glext.h
211 %{_includedir}/GL/gl_mangle.h
212 %{_includedir}/GL/glu.h
213 %{_includedir}/GL/glu_mangle.h
214 %{_includedir}/GL/glx.h
215 %{_includedir}/GL/glxext.h
216 %{_includedir}/GL/glx_mangle.h
217 %{_includedir}/GL/osmesa.h
218 %{_includedir}/GL/xmesa.h
219 %{_includedir}/GL/xmesa_x.h
220 %{_includedir}/GL/xmesa_xf86.h
221 %{_mandir}/man3/*
222
223 %files static
224 %defattr(644,root,root,755)
225 %{_libdir}/libGL.a
226 %{_libdir}/libGLU.a
227 %{_libdir}/libOSMesa.a
228
229 %files demos
230 %defattr(644,root,root,755)
231 %{_examplesdir}/Mesa
This page took 1.021104 seconds and 4 git commands to generate.