1 Summary: A library for working with sizes in bytes
7 Source0: https://github.com/storaged-project/libbytesize/releases/download/%{version}/%{name}-%{version}.tar.gz
8 # Source0-md5: aa9bd5a04546873714da2adbaaa9f283
9 URL: https://github.com/storaged-project/libbytesize
10 BuildRequires: autoconf
11 BuildRequires: automake
12 BuildRequires: gmp-devel
13 BuildRequires: gtk-doc
14 BuildRequires: libtool
15 BuildRequires: mpfr-devel
16 BuildRequires: pcre-devel >= 8.32
17 BuildRequires: pkgconfig
18 BuildRequires: python3-devel
19 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22 The libbytesize is a C library that facilitates work with sizes in
23 bytes. Be it parsing the input from users or producing a nice human
24 readable representation of a size in bytes this library takes
25 localization into account. It also provides support for sizes bigger
29 Summary: Header files for libbytesize library
30 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libbytesize
31 Group: Development/Libraries
32 Requires: %{name} = %{version}-%{release}
35 Header files for libbytesize library.
37 %description devel -l pl.UTF-8
38 Pliki nagłówkowe biblioteki libbytesize.
41 Summary: libbytesize library API documentation
42 Summary(pl.UTF-8): Dokumentacja API biblioteki libbytesize
44 Requires: gtk-doc-common
47 API documentation for libbytesize library.
49 %description apidocs -l pl.UTF-8
50 Dokumentacja API biblioteki libbytesize.
52 %package -n python-bytesize
53 Summary: Python 2 bindings for libbytesize
54 Group: Libraries/Python
55 Requires: %{name} = %{version}-%{release}
58 %description -n python-bytesize
59 This package contains Python 2 bindings for libbytesize.
61 %package -n python3-bytesize
62 Summary: Python 3 bindings for libbytesize
63 Group: Libraries/Python
64 Requires: %{name} = %{version}-%{release}
67 %description -n python3-bytesize
68 This package contains Python 3 bindings for libbytesize.
82 rm -rf $RPM_BUILD_ROOT
83 install -d $RPM_BUILD_ROOT%{_gtkdocdir}
86 DESTDIR=$RPM_BUILD_ROOT
88 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
89 %py_comp $RPM_BUILD_ROOT%{py_sitedir}
92 %py3_comp $RPM_BUILD_ROOT%{py3_sitedir}
93 %py3_ocomp $RPM_BUILD_ROOT%{py3_sitedir}
95 %{__rm} $RPM_BUILD_ROOT%{_libdir}/*.la
97 %{__mv} $RPM_BUILD_ROOT{%{_datadir}/gtk-doc/html/libbytesize,%{_gtkdocdir}}
102 rm -rf $RPM_BUILD_ROOT
104 %post -p /sbin/ldconfig
105 %postun -p /sbin/ldconfig
107 %files -f %{name}.lang
108 %defattr(644,root,root,755)
110 %attr(755,root,root) %{_libdir}/libbytesize.so.*.*.*
111 %attr(755,root,root) %ghost %{_libdir}/libbytesize.so.1
114 %defattr(644,root,root,755)
115 %attr(755,root,root) %{_libdir}/libbytesize.so
116 %{_includedir}/bytesize
117 %{_pkgconfigdir}/bytesize.pc
120 %defattr(644,root,root,755)
121 %{_gtkdocdir}/libbytesize
123 %files -n python-bytesize
124 %defattr(644,root,root,755)
125 %dir %{py_sitedir}/bytesize
126 %{py_sitedir}/bytesize/*.py[co]
128 %files -n python3-bytesize
129 %defattr(644,root,root,755)
130 %dir %{py3_sitedir}/bytesize
131 %{py3_sitedir}/bytesize/__pycache__
132 %{py3_sitedir}/bytesize/*.py