source: projects/specs/trunk/c/createrepo_c/createrepo_c-vl.spec @ 12545

Revision 12545, 16.8 KB checked in by tomop, 3 years ago (diff)

rpm-4.16.1.2-1 and requirements

Line 
1%{!?_licensedir:%global license %%doc}
2
3%global bash_completion %config%{_sysconfdir}/bash_completion.d/createrepo_c.bash
4
5%{!?python2_sitearch:%global python2_sitearch %{python_sitearch}}
6
7%bcond_without python3
8%bcond_with    drpm
9
10Summary:        Creates a common metadata repository
11Name:           createrepo_c
12Version:        0.17.0
13Release:        1%{?_dist_release}
14Group:          admin-tools
15Vendor:         Project Vine
16Distribution:   Vine Linux
17
18License:        GPLv2+
19URL:            https://github.com/rpm-software-management/createrepo_c
20Source0:        %{url}/archive/%{version}/%{name}-%{version}.tar.gz
21
22BuildRequires:  cmake
23BuildRequires:  gcc
24BuildRequires:  bzip2-devel
25BuildRequires:  doxygen
26BuildRequires:  expat-devel
27BuildRequires:  file-devel
28BuildRequires:  glib2-devel >= 2.22.0
29BuildRequires:  curl-devel
30BuildRequires:  libxml2-devel
31BuildRequires:  openssl-devel
32BuildRequires:  rpm-devel >= 4.8.0-28
33BuildRequires:  sqlite3-devel
34BuildRequires:  xz-devel
35BuildRequires:  zlib-devel
36Requires:       %{name}-libs =  %{version}-%{release}
37BuildRequires:  bash-completion
38%if %{with drpm}
39BuildRequires:  drpm-devel >= 0.1.3
40%endif
41Requires: rpm >= 4.16.0
42
43%description
44C implementation of Createrepo.
45A set of utilities (createrepo_c, mergerepo_c, modifyrepo_c)
46for generating a common metadata repository from a directory of
47rpm packages and maintaining it.
48
49
50%package libs
51Summary:    Library for repodata manipulation
52Group:      system
53
54%description libs
55Libraries for applications using the createrepo_c library
56for easy manipulation with a repodata.
57
58
59%package devel
60Summary:    Library for repodata manipulation
61Group:      programming
62Requires:   %{name}-libs%{?_isa} = %{version}-%{release}
63
64%description devel
65This package contains the createrepo_c C library and header files.
66These development files are for easy manipulation with a repodata.
67
68
69%if %{with python3}
70%package -n python3-%{name}
71Summary:        Python 3 bindings for the createrepo_c library
72Group:          programming
73%{?python_provide:%python_provide python3-%{name}}
74BuildRequires:  python3-rpm-macros
75BuildRequires:  python3-devel
76BuildRequires:  python3-nose
77BuildRequires:  python3-sphinx
78Requires:       %{name}-libs = %{version}-%{release}
79
80%description -n python3-%{name}
81Python 3 bindings for the createrepo_c library.
82%endif
83
84
85%debug_package
86
87
88%prep
89%setup -q
90mkdir build
91
92
93%build
94# Build createrepo_c with Python
95pushd build
96%cmake ../ \
97        -DPYTHON_DESIRED:FILEPATH=%{__python3} \
98        -DWITH_ZCHUNK=OFF \
99        -DWITH_LIBMODULEMD=OFF \
100        -DENABLE_DRPM=OFF
101
102make %{?_smp_mflags} RPM_OPT_FLAGS="%{optflags}"
103# Build C documentation
104make doc-c
105popd
106
107
108%install
109rm -rf %{buildroot}
110pushd build
111  make install DESTDIR=%{buildroot}
112popd
113
114ln -sr %{buildroot}%{_bindir}/createrepo_c %{buildroot}%{_bindir}/createrepo
115ln -sr %{buildroot}%{_bindir}/mergerepo_c %{buildroot}%{_bindir}/mergerepo
116ln -sr %{buildroot}%{_bindir}/modifyrepo_c %{buildroot}%{_bindir}/modifyrepo
117
118
119%check
120pushd build
121  # Compile C tests
122  make tests
123  # Run Python3 tests
124  make ARGS="-V" test
125popd
126
127
128%post libs -p /sbin/ldconfig
129%postun libs -p /sbin/ldconfig
130
131
132%files
133%license COPYING
134%doc README.md
135%{_mandir}/man8/createrepo_c.8*
136%{_mandir}/man8/mergerepo_c.8*
137%{_mandir}/man8/modifyrepo_c.8*
138%{_mandir}/man8/sqliterepo_c.8*
139#%{bash_completion}
140%{_bindir}/createrepo_c
141%{_bindir}/mergerepo_c
142%{_bindir}/modifyrepo_c
143%{_bindir}/sqliterepo_c
144%{_bindir}/createrepo
145%{_bindir}/mergerepo
146%{_bindir}/modifyrepo
147%dir %{_datadir}/bash-completion
148%dir %{_datadir}/bash-completion/completions
149%{_datadir}/bash-completion/completions/*
150
151%files libs
152%license COPYING
153%{_libdir}/lib%{name}.so.*
154
155%files devel
156%doc build/doc/html
157%{_libdir}/lib%{name}.so
158%{_libdir}/pkgconfig/%{name}.pc
159%{_includedir}/%{name}/
160
161%if %{with python3}
162%files -n python3-%{name}
163%{python3_sitearch}/*
164%endif
165
166
167%changelog
168* Mon Feb 22 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 0.17.0-1
169- new upstream release.
170
171* Mon Aug 17 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 0.16.0-1
172- new upstream release.
173
174* Mon May 20 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 0.13.2-1
175- new upstream release.
176
177* Mon Dec 10 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 0.11.1-1
178- new upstream release.
179
180* Sun Jul 17 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 0.10.0-6
181- initial build for Vine Linux.
182
183* Tue Apr 12 2016 Igor Gnatenko <ignatenko@redhat.com> - 0.10.0-5
184- Make drpm builds conditional
185
186* Sun Apr 10 2016 Igor Gnatenko <ignatenko@redhat.com> - 0.10.0-4
187- Don't own python3_sitearch dir in python3 subpkg
188- Use %%license macro
189- Follow modern packaging guidelines
190- Cleanups in spec file
191- Follow packaging guidelines about SourceURL
192- Fix license
193
194* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.10.0-3
195- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
196
197* Fri Jan 8 2016 Orion Poplawski <orion@cora.nwra.com> - 0.10.0-2
198- Remove comments causing trouble with post/postun scriptlets
199
200* Tue Jan   5 2016 Tomas Mlcoch <tmlcoch at redhat.com> - 0.10.0-1
201- Python 3 support (made by Ralph Bean)
202- Modify gen_rst.py to indicate --sqliterepo is an option too (Neal Gompa)
203- Do not compress manpages at generation time (Neal Gompa)
204
205* Tue Oct  20 2015 Tomas Mlcoch <tmlcoch at redhat.com> - 0.9.1-1
206- Fix double free during parsing broken XML metadata (Issue #33)
207- Tests: Add acceptance test for --general-compress-type option
208- Fix 'CR_CW_UNKNOWN_COMPRESSION cannot be used' error
209- Refactoring: Fix compiler warnings
210- Add --general-compress-type option (RhBug 1253850)
211- Enable drpm support when drpm library is detected on system (RhBug: 1261031) (Issue #37)
212- fix traceback on non-complete datetime information (Jarek Polok)
213- parsehdr: Skip broken dependency with bad (non-numerical) epoch and print warning about that
214  (https://lists.fedoraproject.org/pipermail/devel/2015-August/213882.html)
215- misc: cr_str_to_evr(): Return NULL instead of "0" for bad (non-numerical) epoch
216- updateinfo: Fix a typo in the package release attribute (Luke Macken)
217- CMake: Don't require CXX compiler
218- Tests for different checksum type for RPMs and repodata files (#31)
219- Support different checksum type for RPMs and repodata files (#31)
220
221* Tue Jul   7 2015 Tomas Mlcoch <tmlcoch at redhat.com> - 0.9.0-2
222- Add drpm as a BuildRequire
223
224* Thu May  28 2015 Tomas Mlcoch <tmlcoch at redhat.com> - 0.9.0-1
225- mergerepo_c: Prepend protocol (file://) for URLs in pkgorigins (if --koji is used)
226- Update bash completion
227- doc: Update manpages
228- mergerepo: Fix NVR merging method
229- mergerepo: Fix behavior of --all param
230- createrepo: Add --cut-dirs and --location-prefix options
231- misc: Add cr_cut_dirs()
232- mergerepo: Use better version comparison algorithm
233- utils: Port cr_cmp_version_str() to rpm's algorithm (rpmvercmp)
234- misc: Rename elements in cr_Version structure
235- mergerepo: Fix version-release comparison for packages when --all is used
236- mergerepo: Show warnings if some groupfile cannot be automatically used
237- mergerepo: Exit with error code when a groupfile cannot be copied
238
239* Fri May  15 2015 Tomas Mlcoch <tmlcoch at redhat.com> - 0.8.3-1
240- mergerepo: Do not prepend file:// if protocol is already specified
241
242* Thu May  14 2015 Tomas Mlcoch <tmlcoch at redhat.com> - 0.8.2-1
243- doc: Add man pages for sqliterepo and update manpages for other tools
244- mergerepo: Work only with noarch packages if --koji is used and
245  no archlist is specified
246- mergerepo: Use file:// protocol in local baseurl
247- mergerepo: Do not include baseurl for first repo if --koji is specified (RhBug: 1220082)
248- mergerepo_c: Support multilib arch for --koji repos
249- mergerepo_c: Refactoring
250- Print debug message with version in each tool when --verbose is used
251- modifyrepo: Don't override file with itself (RhBug: 1215229)
252
253* Wed May   6 2015 Tomas Mlcoch <tmlcoch at redhat.com> - 0.8.1-1
254- Fix bash completion for RHEL 6
255
256* Tue May   5 2015 Tomas Mlcoch <tmlcoch at redhat.com> - 0.8.0-1
257- New tool Sqliterepo_c - It generates sqlite databases into repos
258  where the sqlite is missing.
259- Internal refactoring and code cleanup
260
261* Fri Feb  20 2015 Tomas Mlcoch <tmlcoch at redhat.com> - 0.7.7-1
262- Proper directory for temporary files when --local-sqlite is used (Issue #12)
263- Bring bash completion install dir and filenames up to date with current bash-completion
264
265* Thu Jan   8 2015 Tomas Mlcoch <tmlcoch at redhat.com> - 0.7.6-1
266- Python: Add __contains__ method to Repomd() class
267
268* Sun Dec  28 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.7.5-1
269- Python repomd: Support for iteration and indexing by type - e.g. record = repomd['primary']
270- Show warning if an XML parser probably parsed a bad type of medata (New XML parser warning type CR_XML_WARNING_BADMDTYPE)
271- drpm library: Explicitly try to locate libdrpm.so.0
272- deltarpms: Don't show options for delta rpms if support is not available
273
274* Tue Nov  11 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.7.4-1
275- createrepo_c, mergerepo_c: Follow redirs by default while downloading remote repos
276- mergerepo_c: Fix segfault when a package without sourcerpm is part of metadata and --koji option is used
277
278* Mon Nov  10 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.7.3-1
279- xml_parser: Add file path into error messages
280- Refactor: Replace g_error() with g_critical() (RhBug: 1162102)
281
282* Thu Nov  06 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.7.2-1
283- createrepo_c: New option --local-sqlite
284
285* Fri Oct  31 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.7.1-1
286- Mergerepo: Fix mergerepo
287- Mergerepo: Add some debugging of metadata read.
288
289* Mon Oct  20 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.7.0-1
290- deltarpms: Update module to work with current version of drpm
291- mergerepo_c: Add --omit-baseurl option
292- craterepo_c: Gen empty repo if empty pkglist is used
293- Docs: Output python docs to separate directory
294- Several small fixes
295
296* Tue Aug  12 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.6.1-1
297- updateinfo: Use Python datetime objects in python bindings
298
299* Tue Aug   5 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.6.0-1
300- Support for updateinfo.xml manipulation (including Python bindings)
301
302* Fri Jul  18 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.5.0-1
303- Experimental delta rpm (DRPM) support (Disabled in Fedora build).
304
305* Thu Jun  26 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.4.1-1
306- Initialize threads correctly on old versions of GLib2 (RhBug: 1108787)
307- Do not print log domain (get rid off C_CREATEREPOLIB prefix in log messages)
308- Implements support for --cachedir
309- New option --retain-old-md-by-age
310- Few small API changes
311
312* Tue May   6 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.4.0-1
313- Change default behavior of repodata files handling. (RhBug: 1094539)
314  See: https://github.com/Tojaj/createrepo_c/wiki/New-File-Handling
315  By default, createrepo leaves old groupfiles (comps files)
316  in the repodata/ directory during update.
317  Createrepo_c did the same thing but the version 0.4.0 changes this behaviour.
318
319* Thu Apr  10 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.3.1-2
320- Support for weak and rich dependecies
321
322* Mon Mar  10 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.3.0-1
323- Relevant only for developers using createrepo_c library: New approach for
324  metadata loading in case of internal high-level parser functions (see commit
325  messages for more information: d6ed327595, 0b0e75203e, ad1e8450f5)
326- Support for changelog limit value == -1 (include all changelogs)
327- Update debug compilation flags
328- Update man pages (Add synompsis with usage)
329- Update usage examples in help
330
331* Thu Feb  20 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.2.2-1
332- Temporary remove deltarepo subpackages
333- cmake: Do not install deltarepo stuff yet
334- helper: Removed cr_remove_metadata() and cr_get_list_of_md_locations()
335- Add module helpers
336- Sanitize strings before writting them to XML or sqlitedb (ISSUE #3)
337
338* Mon Jan  27 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.2.1-3
339- New expert option: --ignore-lock
340
341* Mon Jan  20 2014 Tomas Mlcoch <tmlcoch at redhat.com> - 0.2.1-2
342- More effort to avoid residual .repodata/ directory on error
343- Add deltarepo and python-deltarepo subpackages
344- Add modifyrepo_c
345- Add documentation for python bindings
346- Refactored code & a lot of little bug fixes
347
348* Wed Aug  14 2013 Tomas Mlcoch <tmlcoch at redhat.com> - 0.2.1-1
349- checksum: Set SHA to be the same as SHA1 (For compatibility with original
350  Createrepo)
351
352* Mon Aug   5 2013 Tomas Mlcoch <tmlcoch at redhat.com> - 0.2.0-1
353- Speedup (More parallelization)
354- Changed C API
355- Add python bindings
356- A lot of bugfixes
357- Add new make targets: tests (make tests - builds c tests) and test
358  (make test - runs c and python test suits).
359- Changed interface of most of C modules - Better error reporting
360  (Add GError ** param).
361- Experimental Python bindings (Beware: The interface is not final yet!).
362- package: Add cr_package_copy method.
363- sqlite: Do not recreate tables and triggers while opening existing db.
364- mergerepo_c: Implicitly use --all with --koji.
365- Man page update.
366
367* Thu Apr  11 2013 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.17-3
368- mergerepo_c: Add --simple-md-filenames and --unique-md-filenames
369options. (RhBug: 950994)
370- mergerepo_c: Always include noarch while mimic koji
371mergerepos. (RhBug: 950991)
372- Rename cr_package_parser_shutdown to cr_package_parser_cleanup()
373- cr_db_info_update is now safe from sqlinjection.
374
375* Mon Mar  25 2013 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.17-1
376- Fix double free() when old metadata parsing failed. (related to RhBug: 920795)
377- Convert all strings to UTF-8 while dumping XML. (related RhBug: 920795)
378
379* Mon Mar  11 2013 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.16-2
380- Remove creation of own empty rpm keyring for a transaction set.
381This is not necessary since rpm-4.8.0-28 (rpm commit
382cad147070e5513312d851f44998012e8f0cdf1e3). Moreover, own rpm keyring
383causes a race condition in threads (causing double free()) which use
384rpmReadPackageFile() called from cr_package_from_rpm().
385
386* Thu Mar  07 2013 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.16-1
387- Fix usage of rpm keyring (RhBug:918645)
388- More generic interface of repomd module
389- Code refactoring
390- Add some usage examples into the doxygen documentation and .h files
391- Rename version constants in version.h
392- New function cr_package_nevra (returns package nevra string)
393
394* Mon Feb  11 2013 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.15-1
395- Fix bug in final move from .repodata/ -> repodata/
396- Fix warnings from RPM library. RPM library is thread-unsafe. This
397includes also reading headers. Use of empty keyring for rpm transaction
398should work around the problem.
399
400* Tue Nov  27 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.14-1
401- Fix filelists database generation (use '.' instead of '' for current dir)
402
403* Tue Nov  20 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.13-1
404- Fix race-condition during task buffering in createrepo_c
405
406* Tue Nov  20 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.12-2
407- Fix removing old repomd.xml while --update
408
409* Thu Nov  15 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.12-1
410- Fix bug in sqlite filelists database
411- Fix memory leak
412
413* Fri Nov  09 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.11-1
414- Deterministic output! Packages in output repodata are now sorted
415by ASCII value
416- Support for Koji mergerepos behaviour in mergerepo_c
417(new --koji, --groupfile and --blocked params)
418- Better atomicity while finall move .repodata/ -> repodata/
419- Repomd module supports pkgorigins record
420- Some new functions in misc module
421- Small changes in library interface
422
423* Wed Oct  03 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.10-1
424- Another memory usage optimalization
425
426* Mon Sep  03 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.9-1
427- Some changes in library interface
428- Memory usage optimalization
429- Fix a segfault and a race condition
430- New cmd options: --read-pkgs-list and --retain-old-md param
431- Few other bugfixes
432
433* Wed Aug  15 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.8-1
434- New interface of repomd module
435- New cmd options: --repo --revision --distro --content --basedir
436- New createrepo_c specific cmd option --keep-all-metadata
437- Few bugfixes
438
439* Thu Jul  26 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.7-1
440- SQLite support
441- Bash completion
442- createrepo_c support for --compress-type param
443- Improved logging
444- Subpackages -devel and -libsi
445- Relicensed to GPLv2
446- Doxygen documentation in devel package
447- README update
448
449* Mon Jun  11 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.5-1
450- Support for .xz compression
451- Unversioned .so excluded from installation
452
453* Mon Jun   4 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.4-1
454- New mergerepo params: --all, --noarch-repo and --method
455- Fix segfault when more than one --excludes param used
456
457* Mon May  28 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.3-1
458- Set RelWithDebInfo as default cmake build type
459
460* Wed May  23 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.2-1
461- Add version.h header file
462
463* Wed May  23 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.1-1
464- Add license
465
466* Wed May  9 2012 Tomas Mlcoch <tmlcoch at redhat.com> - 0.1.0-1
467- First public release
Note: See TracBrowser for help on using the repository browser.