source: projects/specs/trunk/lib/libb/libbytesize/libbytesize-vl.spec @ 12469

Revision 12469, 13.8 KB checked in by tomop, 4 years ago (diff)

python-3.8.5 and related packages.

Line 
1%define realname bytesize
2%define with_python2 0
3%define with_python3 1
4%define with_gtk_doc 1
5
6%if %{with_python3} == 0
7%define python3_opts --without-python3
8%endif
9%if %{with_python2} == 0
10%define python2_opts --without-python2
11%endif
12
13%define configure_opts %{?python3_opts} %{?python2_opts}
14
15Summary:      A library for working with sizes in bytes
16Name:         libbytesize
17Version:      2.4
18Release:      1%{?_dist_release}
19Group:        system
20Vendor:       Project Vine
21Distribution: Vine Linux
22
23License:      LGPLv2+
24URL:          https://github.com/storaged-project/libbytesize
25Source0:      https://github.com/storaged-project/libbytesize/releases/download/%{version}/%{name}-%{version}.tar.gz
26
27BuildRequires: gcc
28BuildRequires: gmp-devel
29BuildRequires: mpfr-devel
30BuildRequires: pcre2-devel
31BuildRequires: gettext-devel
32%if %{with_python2}
33BuildRequires: python-devel
34BuildRequires: python-rpm-macros
35%endif
36%if %{with_python3}
37BuildRequires: python3-devel
38BuildRequires: python3-rpm-macros
39%endif
40%if %{with_gtk_doc}
41BuildRequires: gtk-doc
42%endif
43
44%description
45The libbytesize is a C library that facilitates work with sizes in
46bytes. Be it parsing the input from users or producing a nice human readable
47representation of a size in bytes this library takes localization into
48account. It also provides support for sizes bigger than MAXUINT64.
49
50
51%package devel
52Summary:  Development files for libbytesize
53Group:    programming
54Requires: %{name}%{?_isa} = %{version}-%{release}
55
56%description devel
57This package contains header files and pkg-config files needed for development
58with the libbytesize library.
59
60
61%if %{with_python2}
62%package -n python-%{realname}
63Summary: Python 2 bindings for libbytesize
64Group:   programming
65%{?python_provide:%python_provide python2-%{realname}}
66%{?python_provide:%python_provide python2-libbytesize}
67Requires: %{name}%{?_isa} = %{version}-%{release}
68Requires: python-six
69
70%description -n python-%{realname}
71This package contains Python 2 bindings for libbytesize making the use of
72the library from Python 2 easier and more convenient.
73%endif
74
75
76%if %{with_python3}
77%package -n python3-%{realname}
78Summary: Python 3 bindings for libbytesize
79Group:   programming
80Requires: %{name}%{?_isa} = %{version}-%{release}
81Requires: python3-six
82
83%description -n python3-%{realname}
84This package contains Python 3 bindings for libbytesize making the use of
85the library from Python 3 easier and more convenient.
86%endif
87
88
89%prep
90%setup -q -n %{name}-%{version}
91
92%build
93%configure %{?configure_opts}
94%{__make} %{?_smp_mflags}
95
96%install
97%{make_install}
98find %{buildroot} -type f -name "*.la" | xargs %{__rm}
99%find_lang %{name}
100
101
102%post
103/sbin/ldconfig
104
105%postun
106/sbin/ldconfig
107
108
109%files -f %{name}.lang
110%doc README.md
111%{!?_licensedir:%global license %%doc}
112%license LICENSE
113%{_bindir}/*
114%{_libdir}/libbytesize.so.*
115%{_mandir}/man1/*
116
117%files devel
118%{_libdir}/libbytesize.so
119%dir %{_includedir}/bytesize
120%{_includedir}/bytesize/bs_size.h
121%{_libdir}/pkgconfig/bytesize.pc
122%if %{with_gtk_doc}
123%{_datadir}/gtk-doc/html/libbytesize
124%endif
125
126%if %{with_python2}
127%files -n python-%{realname}
128%dir %{python_sitearch}/bytesize
129%{python_sitearch}/bytesize/*
130%endif
131
132%if %{with_python3}
133%files -n python3-%{realname}
134%dir %{python3_sitearch}/bytesize
135%{python3_sitearch}/bytesize/*
136#%{python3_sitearch}/bytesize/__pycache__/*
137%endif
138
139%changelog
140* Sun Aug 16 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 2.4-1
141- new upstream release.
142
143* Wed Mar 18 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 2.2-1
144- new upstream release.
145
146* Mon Dec 17 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 1.4-2
147- initial build for Vine Linux.
148
149* Thu Aug 02 2018 Vojtech Trefny <vtrefny@redhat.com> - 1.4-1
150- Squashed 'translation-canary/' changes from 840c2d6..fccbb1b (vtrefny)
151- Make sure the test script fails if one of the test runs fail (vtrefny)
152- Do not try to run python2 tests without python2 support (vtrefny)
153- Fix licence header for "gettext.h" (vtrefny)
154- Do not use rpm to check for Zanata client (vtrefny)
155- Use new ldconfig_scriptlets macro in spec (vtrefny)
156
157* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.3-5
158- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
159
160* Mon Jul 02 2018 Miro Hrončok <mhroncok@redhat.com> - 1.3-4
161- Rebuilt for Python 3.7
162
163* Fri Jun 29 2018 Vojtech Trefny <vtrefny@redhat.com> - 1.3-3
164- Use new ldconfig_scriptlets macro in spec
165
166* Fri Jun 15 2018 Miro Hrončok <mhroncok@redhat.com> - 1.3-2
167- Rebuilt for Python 3.7
168
169* Thu Apr 19 2018 Vojtech Trefny <vtrefny@redhat.com> - 1.3-1
170- Allow building libbytesize without Python 2 support (vtrefny)
171- Sync spec with downstream (vtrefny)
172- Add gcc to BuildRequires (vtrefny)
173- Fix links for documentation and GH project (vtrefny)
174- Add a HACKING.rst file (vpodzime)
175- Do not segfault when trying to bs_size_free NULL (vtrefny)
176
177* Wed Feb 21 2018 Vojtech Trefny <vtrefny@redhat.com> - 1.2-4
178- Add gcc to BuildRequires (vtrefny)
179
180* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.2-3
181- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
182
183* Fri Jan 05 2018 Iryna Shcherbina <ishcherb@redhat.com> - 1.2-2
184- Update Python 2 dependency declarations to new packaging standards
185  (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)
186
187* Fri Sep 29 2017 Vratislav Podzimek <vpodzime@redhat.com> - 1.2-1
188- Use only version as a tag of the last release (vpodzime)
189- Do not require the glib-2.0 pkgconfig package (vpodzime)
190- Do not lie about tag creation (vpodzime)
191
192* Thu Sep 28 2017 Troy Dawson <tdawson@redhat.com> - 1.1-2
193- Cleanup spec file conditionals
194
195* Thu Sep 21 2017 Vratislav Podzimek <vpodzime@redhat.com> - 1.1-1
196- Add NEWS.rst file (vtrefny)
197- Fix source and url in spec file (vtrefny)
198- Use only one git tag for new releases (vtrefny)
199- Actually translate the units when expected (vpodzime)
200- Add two temporary test files to .gitignore (vpodzime)
201
202* Thu Sep 14 2017 Vratislav Podzimek <vpodzime@redhat.com> - 1.0-1
203- Make more space for CI status image (vtrefny)
204- Include limits.h to make sure ULONG_MAX is defined (vpodzime)
205- Remove extra 'is' in two docstrings (vpodzime)
206- Properly support 64bit operands (vpodzime)
207
208* Sat Aug 19 2017 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 0.11-4
209- Python 2 binary package renamed to python2-libbytesize
210  See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3
211
212* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.11-3
213- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
214
215* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.11-2
216- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
217
218* Wed Jun 14 2017 Vratislav Podzimek <vpodzime@redhat.com> - 0.11-1
219- Fix README file name (vtrefny)
220- Add a build status image to the README.md (vpodzime)
221- Remove "glibc-all-langpacks" from test dependencies (vtrefny)
222- Check for requires in generated spec file, not in the template (vtrefny)
223- Fix checking for available locales (vtrefny)
224- Fix library name in acinclude.m4 (vtrefny)
225- Do not try to run translation tests on CentOS/RHEL 7 (vtrefny)
226- Skip tests if they require unavailable locales (vpodzime)
227
228* Wed Apr 19 2017 Vratislav Podzimek <vpodzime@redhat.com> - 0.10-1
229- Fix installation without specifying --exec-prefix (martin)
230- Sync the spec file with downstream (vpodzime)
231
232* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.9-2
233- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
234
235* Wed Jan 11 2017 Vratislav Podzimek <vpodzime@redhat.com> - 0.9-1
236- Allow the Size python class to be easily imported (vpodzime)
237- Make sure pyexecdir is defined (vpodzime)
238- Do not run Python 3 tests without python3 (vpodzime)
239- Disable python3 on RHEL (vpodzime)
240- Reflect the configuration in the spec file template (vpodzime)
241- Make documentation generation conditional (vpodzime)
242- Make python3 support conditional (vpodzime)
243- Require lower version of libpcre (vpodzime)
244- Sync the spec file with downstream (vpodzime)
245
246* Wed Dec 21 2016 Adam Williamson <awilliam@redhat.com> - 0.8-2
247- Rebuild for Python 3.6, again
248
249* Fri Dec 16 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.8-1
250- Add a docstring to python bindings (vpodzime)
251- Neutralize None as an operand for math operations (vpodzime)
252- Add targets for checking and installing test requirements (vpodzime)
253- Fix 'make local' (vtrefny)
254- Make the python packages own their package directories (vpodzime)
255- Don't compare translated and untranslated representations (vpodzime)
256- replace_char_with_str: Fix the character count. (dshea)
257- Ditch autopoint. (dshea)
258
259* Mon Dec 12 2016 Charalampos Stratakis <cstratak@redhat.com> - 0.7-4
260- Rebuild for Python 3.6
261
262* Tue Sep 20 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.7-3
263- Prevent ignored exceptions in __del__ from happening (vpodzime)
264
265* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.7-2
266- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
267
268* Tue May 17 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.7-1
269- Re-run autogen.sh and configure before updating the .pot file (vpodzime)
270- Change where tests on translated strings are run. (dshea)
271- Squashed 'translation-canary/' changes from d6c0708..840c2d6 (dshea)
272- Make sure we get the tests result report in 'make ci' (vpodzime)
273- Add a new generic error code/enum for failures (vpodzime)
274- Do not ignore the return value from asprintf() (vpodzime)
275- Beware of the radix char when converting to Decimal (#1325705) (vpodzime)
276
277* Fri May  6 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.6-2
278- Beware of unsigned long int on 32bit arches (#1333149) (vpodzime)
279
280* Tue May 03 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.6-1
281- Add support for the ROUND_HALF_UP rounding mode (vpodzime)
282- Make sure we return the right radix char in human_readable() (vpodzime)
283- Allocate enough memory for char->str replacements (vpodzime)
284
285* Tue Apr 26 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.5-1
286- Create both libbytesize-$version and $version tags (vpodzime)
287- Update the .pot file with the new version (vpodzime)
288- Improve how we create changelog (vpodzime)
289- Try harder when getting OverflowError in division (#1326897) (vpodzime)
290- Neutralize the radix char before passing string to MPFR (#1326108) (vpodzime)
291- Run tests with en_US and fr_FR locales (vpodzime)
292- Run the tests with both python2 and python3 again (vpodzime)
293- Do not run the same tests 3 times as part of the 'ci' target (vpodzime)
294- Don't fail if just the best-effort cleanup fails (vpodzime)
295- Throw away the new .pot file when just running tests (vpodzime)
296- Make sure we return one of -1, 0, 1 from cmp functions (#1326113) (vpodzime)
297- Use cmp_bytes(size, bytes) when comparing to 0 (vpodzime)
298- Ignore all .po~ files (vpodzime)
299- Add translator comments (dshea)
300- Integrate translation-canary into the build. (dshea)
301- Run the translation-canary tests from make check. (dshea)
302- Squashed 'translation-canary/' content from commit d6c0708 (dshea)
303- Make 'make check' work. (dshea)
304- Remove files from po/ we don't need to track (vpodzime)
305- Ignore the compiled translation files (vpodzime)
306- Distribute and package the translations (vpodzime)
307- Add the necessary pieces for getting translations (vpodzime)
308
309* Thu Apr 14 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.4-3
310- Only require -lgmp and -lmpfr for static linking (vpodzime)
311
312* Fri Mar 11 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.4-2
313- Do not try to delete the C struct twice (vpodzime)
314
315* Wed Mar 09 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.4-1
316- Add the __init__.py file to provide a proper package (vpodzime)
317- Merge pull request #7 from vpodzime/master-decimal_locale (vpodzime)
318- Make sure we pass a locale-agnostic string to Decimal() (vpodzime)
319- Adapt the package description to no longer using GI (vpodzime)
320- Make Size instances hashable (vpodzime)
321- Sync the spec file with downstream (vpodzime)
322
323* Wed Mar  9 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.3-3
324- Make sure we pass a locale-agnostic string to Decimal() (vpodzime)
325
326* Mon Mar  7 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.3-2
327- Make Size instances hashable (vpodzime)
328
329* Fri Feb 26 2016 Vratislav Podzimek <vpodzime@redhat.com> - 0.3-1
330- Packaging changes related to getting rid of GLib/GObject (vpodzime)
331- Adapt the python bindings and tests (vpodzime)
332- Get rid of GObject and GLib (vpodzime)
333- Define the __divmod__ method even for not dividing by Size (vpodzime)
334
335* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.2-3
336- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
337
338* Tue Nov 10 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.2-2
339- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
340
341* Fri Oct 23 2015 Vratislav Podzimek <vpodzime@redhat.com> - 0.2-1
342- Distribute the tests for overrides (vpodzime)
343- Fix the rpmlog target (vpodzime)
344- Respect the signs when doing division (vpodzime)
345- Add two more internal methods that may be required (vpodzime)
346- Do not pass negative numbers as guint64 when comparing with negative ints (vpodzime)
347- Round toward zero when converting bytes from float to int (vpodzime)
348- Make sure we return Size if doing operations with big integers (vpodzime)
349- Implement the __divmod__() method (vpodzime)
350- Do not try to convert negative int to an unsigned int when multiplying (vpodzime)
351- Fix and test the __deepcopy__ method (vpodzime)
352- Implement the evaluation of Size instance as a bool value (vpodzime)
353- Fix some issues in comparison functions and add tests (vpodzime)
354- Add a function for getting string representation of a unit (vpodzime)
355- Hook the overrides tests to the 'test' target (vpodzime)
356- Merge pull request #4 from japokorn/master-tests_03_python_override (vpodzime)
357- Added tests for Python override (japokorn)
358- Make sure our tests don't get broken by installed overrides (vpodzime)
359
360* Wed Oct 07 2015 Vratislav Podzimek <vpodzime@redhat.com> - 0.1-1
361- Initial release
Note: See TracBrowser for help on using the repository browser.