3 %bcond_without apidocs # (Sphinx based) API documentation
5 Summary: CBOR protocol implementation
6 Summary(pl.UTF-8): Implementacja protokołu CBOR
12 #Source0Download: https://github.com/PJK/libcbor/releases
13 Source0: https://github.com/PJK/libcbor/archive/v%{version}/%{name}-%{version}.tar.gz
14 # Source0-md5: dd39ecd3e3c7adf2eccc585e5c2c2265
15 URL: http://libcbor.org/
16 BuildRequires: cmake >= 3.2
18 BuildRequires: python3-breathe
19 BuildRequires: python3-sphinx_rtd_theme
20 BuildRequires: sphinx-pdg-3
22 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25 libcbor is a C library for parsing and generating CBOR (RFC 7049), the
26 general-purpose schema-less binary data format.
28 %description -l pl.UTF-8
29 libcbor to biblioteka C do analizy i generowania formatu danych CBOR
30 (RFC 7049) - pozbawionego schematu binarnego formatu danych ogólnego
34 Summary: Header files for libcbor library
35 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libcbor
36 Group: Development/Libraries
37 Requires: %{name} = %{version}-%{release}
40 Header files for libcbor library.
42 %description devel -l pl.UTF-8
43 Pliki nagłówkowe biblioteki libcbor.
46 Summary: API documentation for libcbor library
47 Summary(pl.UTF-8): Dokumentacja API biblioteki libcbor
52 API documentation for libcbor library.
54 %description apidocs -l pl.UTF-8
55 Dokumentacja API biblioteki libcbor.
63 # expects CMAKE_INSTALL_LIBDIR relative to prefix
65 -DCMAKE_INSTALL_LIBDIR=%{_lib}
71 %{__make} -C doc html \
72 SPHINXBULD=sphinx-build-3
76 rm -rf $RPM_BUILD_ROOT
78 %{__make} -C build install \
79 DESTDIR=$RPM_BUILD_ROOT
82 rm -rf $RPM_BUILD_ROOT
84 %post -p /sbin/ldconfig
85 %postun -p /sbin/ldconfig
88 %defattr(644,root,root,755)
89 %doc CHANGELOG.md LICENSE.md README.md
90 %attr(755,root,root) %{_libdir}/libcbor.so.*.*.*
91 %attr(755,root,root) %ghost %{_libdir}/libcbor.so.0.11
94 %defattr(644,root,root,755)
95 %attr(755,root,root) %{_libdir}/libcbor.so
98 %{_pkgconfigdir}/libcbor.pc
99 %{_libdir}/cmake/libcbor
103 %defattr(644,root,root,755)
104 %doc doc/build/html/{_static,api,*.html,*.js}