]> git.pld-linux.org Git - packages/Mesa-libGLU.git/blobdiff - Mesa-libGLU.spec
- updated to 9.0.3, now uses meson; rely on glvnd by default
[packages/Mesa-libGLU.git] / Mesa-libGLU.spec
index 32cd81376979dc6e49eb7d04e4507b049b7879ea..3b947fc6a28e160fceb0ee26eef20845184ab158 100644 (file)
@@ -1,23 +1,32 @@
 #
 # Conditional build:
+%bcond_without glvnd           # use GLVND as OpenGL provider
+%bcond_with    osmesa          # use OSMesa as OpenGL provider
 %bcond_without static_libs     # static library
 #
+%if %{without glvnd} && %{without osmesa}
+%define        with_generic_opengl     1
+%endif
 Summary:       SGI implementation of libGLU OpenGL library
 Summary(pl.UTF-8):     Implementacja SGI biblioteki libGLU ze standardu OpenGL
 Name:          Mesa-libGLU
-Version:       9.0.0
+Version:       9.0.3
 Release:       1
 License:       SGI Free Software License B v2.0 (MIT-like)
 Group:         Libraries
-Source0:       ftp://ftp.freedesktop.org/pub/mesa/glu/glu-%{version}.tar.bz2
-# Source0-md5: be9249132ff49275461cf92039083030
-URL:           http://www.mesa3d.org/
-BuildRequires: OpenGL-devel >= 1.2
-BuildRequires: autoconf >= 2.60
-BuildRequires: automake
+Source0:       https://archive.mesa3d.org/glu/glu-%{version}.tar.xz
+# Source0-md5: 06a4fff9179a98ea32ef41b6d83f6b19
+URL:           https://www.mesa3d.org/
+%{?with_osmesa:BuildRequires:  Mesa-libOSMesa-devel}
+%{?with_generic_opengl:BuildRequires:  OpenGL-devel >= 1.2}
+%{?with_glvnd:BuildRequires:   libglvnd-libGL-devel}
 BuildRequires: libstdc++-devel
-BuildRequires: libtool >= 2:2.2
+BuildRequires: meson >= 0.52.0
+BuildRequires: ninja >= 1.5
 BuildRequires: pkgconfig
+BuildRequires: rpmbuild(macros) >= 1.736
+BuildRequires: tar >= 1:1.22
+BuildRequires: xz
 Requires:      OpenGL >= 1.2
 Provides:      OpenGL-GLU = 1.3
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -35,7 +44,9 @@ Summary:      Header files for SGI libGLU library
 Summary(pl.UTF-8):     Pliki nagłówkowe biblioteki SGI libGLU
 Group:         Development/Libraries
 Requires:      %{name} = %{version}-%{release}
-Requires:      OpenGL-devel >= 1.2
+%{?with_osmesa:Requires:       Mesa-libOSMesa-devel}
+%{?with_generic_opengl:Requires:       OpenGL-devel >= 1.2}
+%{?with_glvnd:Requires:        libglvnd-libGL-devel}
 Provides:      OpenGL-GLU-devel = 1.3
 
 %description devel
@@ -61,24 +72,16 @@ Statyczna biblioteka SGI libGLU.
 %setup -q -n glu-%{version}
 
 %build
-%{__libtoolize}
-%{__aclocal}
-%{__autoconf}
-%{__automake}
-%configure \
-       --disable-silent-rules \
-       %{!?with_static_libs:--disable-static}
+%meson build \
+       %{!?with_static_libs:--default-library=shared} \
+       %{!?with_glvnd:-Dgl_provider=%{?with_osmesa:osmesa}%{!?with_osmesa:gl}}
 
-%{__make}
+%ninja_build -C build
 
 %install
 rm -rf $RPM_BUILD_ROOT
 
-%{__make} install \
-       DESTDIR=$RPM_BUILD_ROOT
-
-# there is pkg-config support; also, traditionally libGLU didn't have .la
-%{__rm} $RPM_BUILD_ROOT%{_libdir}/libGLU.la
+%ninja_install -C build
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -95,7 +98,6 @@ rm -rf $RPM_BUILD_ROOT
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_libdir}/libGLU.so
 %{_includedir}/GL/glu.h
-%{_includedir}/GL/glu_mangle.h
 %{_pkgconfigdir}/glu.pc
 
 %if %{with static_libs}
This page took 0.066621 seconds and 4 git commands to generate.