]> git.pld-linux.org Git - packages/GLM.git/blob - GLM.spec
d23cff6260ae638da9f6e44c9e73f282ed986147
[packages/GLM.git] / GLM.spec
1 #
2 # Conditional build:
3 %bcond_without  tests           # build without tests
4 %bcond_with     p7zip           # plain p7zip (compatible with both rpm4/rpm5)
5 #
6 Summary:        OpenGL Mathematics (GLM) - C++ mathematics library for GLSL
7 Summary(pl.UTF-8):      OpenGL Mathematics (GLM) - biblioteka matematyczna C++ dla GLSL
8 Name:           GLM
9 Version:        0.9.9.6
10 Release:        1
11 License:        MIT
12 Group:          Development/Libraries
13 #Source0Download: https://github.com/g-truc/glm/releases
14 Source0:        https://github.com/g-truc/glm/releases/download/%{version}/glm-%{version}.7z
15 # Source0-md5:  546245878ba4fc64f9af03c1c88b9ec9
16 Patch0:         %{name}-opt.patch
17 Patch1:         x32.patch
18 URL:            https://glm.g-truc.net/
19 BuildRequires:  cmake >= 3.2
20 %if %{with p7zip}
21 BuildRequires:  p7zip
22 %else
23 BuildRequires:  p7zip-standalone
24 BuildRequires:  rpm-build >= 5
25 %endif
26 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28 %description
29 OpenGL Mathematics (GLM) is a C++ mathematics library for graphics
30 software based on the OpenGL Shading Language (GLSL) specification.
31
32 GLM is a header only library, there is nothing to build, just include
33 it.
34
35 %description -l pl.UTF-8
36 OpenGL Mathematics (GLM) to biblioteka matematyczna C++ dla programów
37 graficznych opartych na specyfikacji OpenGL Shading Language (GLSL).
38
39 %prep
40 %if %{with p7zip}
41 %setup -q -c -T -n glm
42 7z x %{SOURCE0} -o..
43 %else
44 %setup -q -n glm
45 %endif
46 %patch0 -p1
47 %patch1 -p1
48
49 %build
50 mkdir build
51 cd build
52 %cmake .. \
53         -DGLM_TEST_ENABLE:BOOL=%{!?with_tests:OFF}%{?with_tests:ON}
54
55 %if %{with tests}
56 %{__make}
57 %{__make} test
58 %endif
59
60 %install
61 rm -rf $RPM_BUILD_ROOT
62 install -d $RPM_BUILD_ROOT%{_includedir}
63
64 cp -a glm $RPM_BUILD_ROOT%{_includedir}
65
66 %clean
67 rm -rf $RPM_BUILD_ROOT
68
69 %files
70 %defattr(644,root,root,755)
71 %doc manual.md readme.md
72 %{_includedir}/glm
This page took 0.044785 seconds and 2 git commands to generate.