]>
Commit | Line | Data |
---|---|---|
ff84a361 JP |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without apidocs # Doxygen based API documentation | |
4 | ||
5 | Summary: Wayland C++ bindings | |
6 | Name: waylandpp | |
7 | Version: 0.2.8 | |
8 | Release: 1 | |
9 | License: MIT | |
10 | Group: Libraries | |
11 | Source0: https://github.com/NilsBrause/waylandpp/archive/%{version}/%{name}-%{version}.tar.gz | |
12 | # Source0-md5: f930127bb8dee80128c95622e1947f0c | |
13 | URL: https://nilsbrause.github.io/waylandpp_docs/ | |
14 | BuildRequires: cmake >= 3.4 | |
15 | %{?with_apidocs:BuildRequires: doxygen} | |
16 | BuildRequires: libstdc++-devel >= 6:4.8 | |
17 | BuildRequires: pkgconfig | |
18 | BuildRequires: pugixml-devel >= 1.4 | |
19 | BuildRequires: rpm-build >= 4.6 | |
20 | BuildRequires: rpmbuild(macros) >= 1.742 | |
21 | BuildRequires: wayland-devel >= 1.11.0 | |
22 | BuildRequires: wayland-egl-devel | |
23 | Requires: wayland >= 1.11.0 | |
24 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
25 | ||
26 | # project claims missing symbols are intentional and even tries to | |
27 | # remove -Wl,--no-undefined from linker flags | |
28 | %define no_install_post_check_so 1 | |
29 | ||
30 | %description | |
31 | The goal of this library is to create such a C++ binding for Wayland | |
32 | using the most modern C++ technology currently available, providing an | |
33 | easy to use C++ API to Wayland. | |
34 | ||
35 | %package devel | |
36 | Summary: Header files for Waylandpp libraries | |
37 | Group: Development/Libraries | |
38 | Requires: %{name} = %{version}-%{release} | |
39 | Requires: pugixml >= 1.4 | |
40 | Requires: wayland-devel >= 1.11.0 | |
41 | Requires: wayland-egl-devel | |
42 | ||
43 | %description devel | |
44 | Header files for Waylandpp libraries. | |
45 | ||
46 | %package apidocs | |
47 | Summary: Waylandpp API documentation | |
48 | Group: Documentation | |
49 | BuildArch: noarch | |
50 | ||
51 | %description apidocs | |
52 | Waylandpp API documentation. | |
53 | ||
54 | %prep | |
55 | %setup -q | |
56 | ||
57 | %build | |
58 | %cmake -B build \ | |
59 | %{cmake_on_off apidocs BUILD_DOCUMENTATION} | |
60 | ||
61 | %{__make} -C build | |
62 | ||
63 | %install | |
64 | rm -rf $RPM_BUILD_ROOT | |
65 | ||
66 | %{__make} -C build install \ | |
67 | DESTDIR=$RPM_BUILD_ROOT | |
68 | ||
69 | %{?with_apidocs:%{__rm} -r $RPM_BUILD_ROOT%{_docdir}} | |
70 | ||
71 | %clean | |
72 | rm -rf $RPM_BUILD_ROOT | |
73 | ||
74 | %post -p /sbin/ldconfig | |
75 | %postun -p /sbin/ldconfig | |
76 | ||
77 | %files | |
78 | %defattr(644,root,root,755) | |
79 | %doc LICENSE README.md | |
80 | %attr(755,root,root) %{_libdir}/libwayland-client++.so.*.*.* | |
81 | %attr(755,root,root) %ghost %{_libdir}/libwayland-client++.so.0 | |
82 | %attr(755,root,root) %{_libdir}/libwayland-client-extra++.so.*.*.* | |
83 | %attr(755,root,root) %ghost %{_libdir}/libwayland-client-extra++.so.0 | |
84 | %attr(755,root,root) %{_libdir}/libwayland-cursor++.so.*.*.* | |
85 | %attr(755,root,root) %ghost %{_libdir}/libwayland-cursor++.so.0 | |
86 | %attr(755,root,root) %{_libdir}/libwayland-egl++.so.*.*.* | |
87 | %attr(755,root,root) %ghost %{_libdir}/libwayland-egl++.so.0 | |
88 | ||
89 | %files devel | |
90 | %defattr(644,root,root,755) | |
91 | %attr(755,root,root) %{_bindir}/wayland-scanner++ | |
92 | %attr(755,root,root) %{_libdir}/libwayland-client++.so | |
93 | %attr(755,root,root) %{_libdir}/libwayland-client-extra++.so | |
94 | %attr(755,root,root) %{_libdir}/libwayland-cursor++.so | |
95 | %attr(755,root,root) %{_libdir}/libwayland-egl++.so | |
2f2656ab JP |
96 | %dir %{_datadir}/waylandpp |
97 | %dir %{_datadir}/waylandpp/protocols | |
98 | %{_datadir}/waylandpp/protocols/*.xml | |
ff84a361 JP |
99 | %{_includedir}/wayland-client*.hpp |
100 | %{_includedir}/wayland-cursor.hpp | |
101 | %{_includedir}/wayland-egl.hpp | |
102 | %{_includedir}/wayland-util.hpp | |
103 | %{_includedir}/wayland-version.hpp | |
104 | %{_libdir}/cmake/waylandpp | |
105 | %{_pkgconfigdir}/wayland-client++.pc | |
106 | %{_pkgconfigdir}/wayland-client-extra++.pc | |
107 | %{_pkgconfigdir}/wayland-cursor++.pc | |
108 | %{_pkgconfigdir}/wayland-egl++.pc | |
109 | %{_pkgconfigdir}/wayland-scanner++.pc | |
110 | %if %{with apidocs} | |
111 | %{_mandir}/man3/wayland_*.3* | |
112 | %{_mandir}/man3/wayland-client.hpp.3* | |
113 | %endif | |
114 | ||
115 | %if %{with apidocs} | |
116 | %files apidocs | |
117 | %defattr(644,root,root,755) | |
118 | %doc build/doc/html | |
119 | %endif |