3 %bcond_without tests # build without tests
5 Summary: OpenGL Mathematics (GLM) - C++ mathematics library for GLSL
6 Summary(pl.UTF-8): OpenGL Mathematics (GLM) - biblioteka matematyczna C++ dla GLSL
12 #Source0Download: https://github.com/g-truc/glm/releases
13 Source0: https://github.com/g-truc/glm/archive/%{version}/glm-%{version}.tar.gz
14 # Source0-md5: f824ac50e16310a95279032f82cbd341
16 URL: https://glm.g-truc.net/
17 BuildRequires: cmake >= 3.6
18 %{?with_tests:BuildRequires: libstdc++-devel}
19 BuildRequires: rpmbuild(macros) >= 1.605
20 Requires: libstdc++-devel
21 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24 OpenGL Mathematics (GLM) is a C++ mathematics library for graphics
25 software based on the OpenGL Shading Language (GLSL) specification.
27 %description -l pl.UTF-8
28 OpenGL Mathematics (GLM) to biblioteka matematyczna C++ dla programów
29 graficznych opartych na specyfikacji OpenGL Shading Language (GLSL).
32 Summary: OpenGL Mathematics (GLM) - C++ mathematics library for GLSL (header files)
33 Summary(pl.UTF-8): OpenGL Mathematics (GLM) - biblioteka matematyczna C++ dla GLSL (pliki nagłówkowe)
34 Group: Development/Libraries
35 Requires: libstdc++-devel
36 # no base dependency - can be used as header-only library
37 # not noarch due to paths in cmake configs
40 OpenGL Mathematics (GLM) is a C++ mathematics library for graphics
41 software based on the OpenGL Shading Language (GLSL) specification.
43 %description devel -l pl.UTF-8
44 OpenGL Mathematics (GLM) to biblioteka matematyczna C++ dla programów
45 graficznych opartych na specyfikacji OpenGL Shading Language (GLSL).
48 %setup -q -n glm-%{version}
54 # change CMAKE_INSTALL_DATAROOTDIR to arch-dependent (files contain arch-dependent libglm.so paths)
56 -DCMAKE_INSTALL_DATAROOTDIR=%{_libdir}/cmake \
57 -DGLM_TEST_ENABLE:BOOL=%{!?with_tests:OFF}%{?with_tests:ON}
66 rm -rf $RPM_BUILD_ROOT
68 %{__make} -C build install \
69 DESTDIR=$RPM_BUILD_ROOT
72 rm -rf $RPM_BUILD_ROOT
74 %post -p /sbin/ldconfig
75 %postun -p /sbin/ldconfig
78 %defattr(644,root,root,755)
79 %doc manual.md readme.md
80 %attr(755,root,root) %{_libdir}/libglm.so
83 %defattr(644,root,root,755)
84 %doc manual.md readme.md