]>
Commit | Line | Data |
---|---|---|
c68e9b0f JB |
1 | # |
2 | # Conditional build: | |
16e9ae49 | 3 | %bcond_without glvnd # use GLVND as OpenGL provider |
c4a5f5fa | 4 | %bcond_with osmesa # use OSMesa as OpenGL provider |
c68e9b0f JB |
5 | %bcond_without static_libs # static library |
6 | # | |
c4a5f5fa JB |
7 | %if %{without glvnd} && %{without osmesa} |
8 | %define with_generic_opengl 1 | |
9 | %endif | |
c68e9b0f JB |
10 | Summary: SGI implementation of libGLU OpenGL library |
11 | Summary(pl.UTF-8): Implementacja SGI biblioteki libGLU ze standardu OpenGL | |
12 | Name: Mesa-libGLU | |
16e9ae49 | 13 | Version: 9.0.3 |
5b7b2319 | 14 | Release: 1 |
c68e9b0f JB |
15 | License: SGI Free Software License B v2.0 (MIT-like) |
16 | Group: Libraries | |
16e9ae49 JB |
17 | Source0: https://archive.mesa3d.org/glu/glu-%{version}.tar.xz |
18 | # Source0-md5: 06a4fff9179a98ea32ef41b6d83f6b19 | |
19 | URL: https://www.mesa3d.org/ | |
c4a5f5fa JB |
20 | %{?with_osmesa:BuildRequires: Mesa-libOSMesa-devel} |
21 | %{?with_generic_opengl:BuildRequires: OpenGL-devel >= 1.2} | |
c4a5f5fa | 22 | %{?with_glvnd:BuildRequires: libglvnd-libGL-devel} |
c68e9b0f | 23 | BuildRequires: libstdc++-devel |
16e9ae49 JB |
24 | BuildRequires: meson >= 0.52.0 |
25 | BuildRequires: ninja >= 1.5 | |
c68e9b0f | 26 | BuildRequires: pkgconfig |
16e9ae49 | 27 | BuildRequires: rpmbuild(macros) >= 1.736 |
5b7b2319 JB |
28 | BuildRequires: tar >= 1:1.22 |
29 | BuildRequires: xz | |
c68e9b0f JB |
30 | Requires: OpenGL >= 1.2 |
31 | Provides: OpenGL-GLU = 1.3 | |
32 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
33 | ||
34 | %description | |
35 | SGI implementation of libGLU OpenGL library. It implements OpenGL GLU | |
36 | 1.3 specifications. | |
37 | ||
38 | %description -l pl.UTF-8 | |
39 | Implementacja SGI biblioteki libGLU ze standardu OpenGL. Implementuje | |
40 | specyfikację OpenGL GLU 1.3. | |
41 | ||
42 | %package devel | |
43 | Summary: Header files for SGI libGLU library | |
44 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki SGI libGLU | |
45 | Group: Development/Libraries | |
46 | Requires: %{name} = %{version}-%{release} | |
c4a5f5fa JB |
47 | %{?with_osmesa:Requires: Mesa-libOSMesa-devel} |
48 | %{?with_generic_opengl:Requires: OpenGL-devel >= 1.2} | |
49 | %{?with_glvnd:Requires: libglvnd-libGL-devel} | |
9b1325b6 | 50 | Provides: OpenGL-GLU-devel = 1.3 |
c68e9b0f JB |
51 | |
52 | %description devel | |
53 | Header files for SGI libGLU library. | |
54 | ||
55 | %description devel -l pl.UTF-8 | |
56 | Pliki nagłówkowe biblioteki SGI libGLU. | |
57 | ||
58 | %package static | |
59 | Summary: Static SGI libGLU library | |
60 | Summary(pl.UTF-8): Statyczna biblioteka SGI libGLU | |
61 | Group: Development/Libraries | |
62 | Requires: %{name}-devel = %{version}-%{release} | |
63 | Provides: OpenGL-GLU-static = 1.3 | |
64 | ||
65 | %description static | |
66 | Static SGI libGLU library. | |
67 | ||
68 | %description static -l pl.UTF-8 | |
69 | Statyczna biblioteka SGI libGLU. | |
70 | ||
71 | %prep | |
72 | %setup -q -n glu-%{version} | |
73 | ||
74 | %build | |
16e9ae49 JB |
75 | %meson build \ |
76 | %{!?with_static_libs:--default-library=shared} \ | |
77 | %{!?with_glvnd:-Dgl_provider=%{?with_osmesa:osmesa}%{!?with_osmesa:gl}} | |
78 | ||
79 | %ninja_build -C build | |
c68e9b0f JB |
80 | |
81 | %install | |
82 | rm -rf $RPM_BUILD_ROOT | |
83 | ||
16e9ae49 | 84 | %ninja_install -C build |
c68e9b0f JB |
85 | |
86 | %clean | |
87 | rm -rf $RPM_BUILD_ROOT | |
88 | ||
89 | %post -p /sbin/ldconfig | |
90 | %postun -p /sbin/ldconfig | |
91 | ||
92 | %files | |
93 | %defattr(644,root,root,755) | |
94 | %attr(755,root,root) %{_libdir}/libGLU.so.*.*.* | |
95 | %attr(755,root,root) %ghost %{_libdir}/libGLU.so.1 | |
96 | ||
97 | %files devel | |
98 | %defattr(644,root,root,755) | |
99 | %attr(755,root,root) %{_libdir}/libGLU.so | |
100 | %{_includedir}/GL/glu.h | |
c68e9b0f JB |
101 | %{_pkgconfigdir}/glu.pc |
102 | ||
103 | %if %{with static_libs} | |
104 | %files static | |
105 | %defattr(644,root,root,755) | |
106 | %{_libdir}/libGLU.a | |
107 | %endif |