Sync from SUSE:SLFO:Main createrepo_c revision 4373d2df0df9e072c9d671d6a901bdf7

This commit is contained in:
Adrian Schröter 2024-05-03 11:54:17 +02:00
commit a31b7310a8
4 changed files with 658 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

BIN
createrepo_c-1.0.2.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

361
createrepo_c.changes Normal file
View File

@ -0,0 +1,361 @@
-------------------------------------------------------------------
Tue Nov 7 15:38:04 UTC 2023 - Dirk Müller <dmueller@suse.com>
- update to 1.0.2:
* Don't allow building without zstd
* Remove dependency on libmagic, hardcode magic number detection
- update to 1.0.1:
* Fix some invalid C code to cover a wider ranger of compilers
* Python API: Fix a crash when setting pkg files
* Add support for building with sanitizers
* Fix a memory leak of nevra in case there are duplicate package
* Free loaded zchunk dictionary
* Fix few deltarpm related memory leaks
update to 1.0.0:
* Add zstd compression support
update to 0.21.1:
* Rename --filelists_ext to --filelists-ext to be consistent
* Change test to compare contents instead of checksum
* Don't remove old metadata packages with --update
* New --duplicated-nevra <solution> option
- drop 0001-Add-optional-filelists_ext-metadata.patch
0002-Rename-filelists_ext-to-filelists-ext-to-be-consiste.patch
0003-Rename-filelists_ext.xml-metadata-to-filelists-ext.x.patch
0004-Add-missing-ext-to-filelists-ext-repomd-record.patch
0005-Complete-renaming-to-filelists-ext.patch: (merged upstream)
-------------------------------------------------------------------
Thu May 18 11:32:19 UTC 2023 - Jiri Srain <jsrain@suse.com>
- disable DeltaRPM for ALP
-------------------------------------------------------------------
Fri Feb 24 16:13:36 UTC 2023 - Bruno Pitrus <brunopitrus@hotmail.com>
- Precompile the python bytecode to avoid lingering files on package removal.
-------------------------------------------------------------------
Wed Feb 22 10:09:43 UTC 2023 - Alberto Planas Dominguez <aplanas@suse.com>
- Add upstream patches (already merged) to publish IMA metadata in
repomd repositories
+ 0001-Add-optional-filelists_ext-metadata.patch
+ 0002-Rename-filelists_ext-to-filelists-ext-to-be-consiste.patch
+ 0003-Rename-filelists_ext.xml-metadata-to-filelists-ext.x.patch
+ 0004-Add-missing-ext-to-filelists-ext-repomd-record.patch
- Add upstream patches (under review) to rename filelists-ext
+ 0005-Complete-renaming-to-filelists-ext.patch
- Use git for merging in %autosetup
-------------------------------------------------------------------
Wed Jul 27 19:34:32 UTC 2022 - Andreas Stieger <andreas.stieger@gmx.de>
- update to 0.20.1:
* fix performance problems with large repositories related to
tasks queue management
-------------------------------------------------------------------
Wed Mar 30 11:39:21 UTC 2022 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.20.0
+ Remove obsoleted API cr_xml_parse_main_metadata_together
+ Fix ampersand encoding in attributes when parsing repodata
+ Add a streaming parsing API that is user-controllable
+ Fix a bug in cr_repomd_record_compress_and_fill()
+ Zero init buffer to prevent use of garbage values if input is too short
+ Use copy+delete fallback when moving of a dir fails
+ Switch default of --keep-all-metadata to TRUE and add --discard-additional-metadata
+ Set database version only for the database records, not everything
+ If the new repodata generated during an --update run exactly matches the old repodata don't touch the files
+ Use --error-exit-val option by default
+ Remove insecure hashes SHA-1 and MD5 from the default build (rh#1935486)
+ Fix error when updating repo with removed modules metadata
+ Exit with status code 1 when loading of repo's metadata fails
+ Fix memory leaks and covscan warnings
-------------------------------------------------------------------
Tue Nov 30 04:52:35 UTC 2021 - Steve Kowalik <steven.kowalik@suse.com>
- python3-nose is not required for the testsuite, update BuildRequires
to the actual package used, python3-setuptools.
-------------------------------------------------------------------
Wed Jun 30 15:35:41 UTC 2021 - Callum Farmer <gmbr3@opensuse.org>
- Update to 0.17.3
+ Remove distutils which are deprecated in python3.10
+ Fix segmentation fault when taking str() of closed file
+ Use pkg-config for rpm libraries instead of custom code
+ Drop Python 2 support
+ Never leave behind .repodata lock on exit
-------------------------------------------------------------------
Fri Feb 26 07:16:58 UTC 2021 - Frank Schreiner <FSchreiner@suse.com>
- removed %is_opensuse (CtLG)
- disabled drpm for SLE/Leap 15.3
-------------------------------------------------------------------
Tue Jul 7 01:12:50 UTC 2020 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.16.0
+ Never do dir walk when --recycle-pkglist specified
+ Add automatic module metadata handling for repos (rh#1795936)
-------------------------------------------------------------------
Tue Jun 30 14:20:03 UTC 2020 - Callum Farmer <callumjfarmer13@gmail.com>
- Update to 0.15.11
+ Add python unittest for invalid date in updateinfo record get_datetime
+ Simplify case when attr is empty (prevents covscan warnings)
+ Fix couple of memory leaks, some mistakenly dead code and error handling
+ Add --arch-expand option
+ Fix spelling errors.
-------------------------------------------------------------------
Tue Feb 18 13:27:23 UTC 2020 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.15.7
+ Add relogin_suggested to updatecollectionpackage (rh#1779751)
+ Support issued date in epoch format in Python API (rh#1779751)
-------------------------------------------------------------------
Sun Jan 19 14:36:38 UTC 2020 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.15.6
+ Set global_exit_status on sigint so that .repodata are cleaned up
+ Fix various issues discovered by covscans (rh#1789707)
+ Enhance error handling when locating repositories (rh#1762697)
+ Switch updateinfo to explicitly include bool values (rh#1772466)
+ add --recycle-pkglist option
+ use pkg href for cache lookup with --update
+ Sync --excludes matching for dir-walk vs. --pkglist
-------------------------------------------------------------------
Fri Dec 6 11:47:37 UTC 2019 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.15.4
+ Add reboot_suggested field to UpdateRecord (rh#1772466)
+ Skip directory matching --exclude right away
+ Add restart_suggested to updatecollectionpackage
-------------------------------------------------------------------
Fri Nov 29 12:42:37 UTC 2019 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.15.3
+ Export all changelog entries in compatibility mode
+ Libmagic to follow symlinks (rh#1776399)
+ Add shortcut to detect *.yaml files as not compressed
- Ensure createrepo_c fully replaces createrepo on Tumbleweed
- Remove old and now unused dependency on deltarpm as drpm is used now
-------------------------------------------------------------------
Mon Nov 25 13:39:11 UTC 2019 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.15.2
+ Fix file mode for cache (rh#1686812)
+ Honor umask on cache files (rh#1686812)
- Enable DeltaRPM support for openSUSE targets on Leap 15.2+ and TW
-------------------------------------------------------------------
Mon Nov 18 05:57:08 UTC 2019 - Steve Kowalik <steven.kowalik@suse.com>
- Add BuildRequires on python3, it won't be pulled in side effect of
requiring python3-nose
-------------------------------------------------------------------
Tue Sep 17 12:00:42 UTC 2019 - Dirk Mueller <dmueller@suse.com>
- fix build by adding missing tarball and updating filelist
-------------------------------------------------------------------
Tue Sep 17 11:43:49 UTC 2019 - Frank Schreiner <FSchreiner@suse.com>
- Update to version 0.15.1:
* Release 0.15.1
* Fix null pointer crash in cr_dumper_thread() if it fails to get checksum
* Fix search in string with missing terminating zero (rh#1750673)
* Depend on DRPM minimum version 0.4.0
* Release 0.15.0
* Revise drpm dependency check and bump the minimum version to 0.3.0
* Release 0.14.4
* Update documentation and regenerate man pages to sync up
* Use drpm_make from drpm instead of deltarpm (rh#1687843)
* Fix some DEBUG build warnings
* Switch off html timestamps on documentation (rh#1731050)
* Update documentation for mergerepo_c merge methods (rh#1722803)
* Update documentation for --retain-old-md and --compatibility
* Fix --read-pkgs-list to only list actually read packages
* Release 0.14.3
* Add missing python metadata to python2/3-createrepo_c (rh#1695677)
* detect plain tar file as non compressed
-------------------------------------------------------------------
Sat Jun 29 13:06:18 UTC 2019 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.14.2
+ Fix issue with createrepo_c hanging at the end (rh#1714666)
+ Don't include packages with forbidden control chars in repodata (boo#1110914)
+ Correct pkg count in headers if there were invalid pkgs (rh#1596211)
+ Prevent exiting with 0 if errors occur while finalizing repodata
-------------------------------------------------------------------
Wed May 15 23:17:38 UTC 2019 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.14.0
+ Fix crash when dumping updateinfo and module is omitted (rh#1707981)
+ Add --pkgorigins mode
-------------------------------------------------------------------
Sat May 4 22:17:16 UTC 2019 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.13.1
+ Fix tests to work properly when modulemd support is not enabled
- Enable modulemd support on openSUSE Leap 15.1+ and Tumbleweed
-------------------------------------------------------------------
Sat May 4 01:39:34 UTC 2019 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.13.0
+ Add support for handling modulemd
+ Add support for Koji simple merge mode
+ Add support for zchunked modulemd
+ Fixed --keep-all-metadata to keep all additional metadata
- Disable tests if modulemd support is not enabled to prevent wrong failures
- Drop patches included in this release
+ 0001-Find-correct-nosetests-version-even-when-which-comma.patch
+ 0002-fix-linking-when-Wl-no-undefined-is-set.patch
-------------------------------------------------------------------
Mon Mar 18 17:16:27 UTC 2019 - Jan Engelhardt <jengelh@inai.de>
- Use noun phrase in summary.
-------------------------------------------------------------------
Fri Mar 01 09:37:11 UTC 2019 - Frank Schreiner <FSchreiner@suse.com>
- Added upstream patches
* 0001-Find-correct-nosetests-version-even-when-which-comma.patch
* 0002-fix-linking-when-Wl-no-undefined-is-set.patch
- Drop included patches
* 0001-zck_end_chunk-returns-number-of-bytes-written-or-1-f.patch
* 0002-Add-missing-sentinal.patch
* 0003-Fix-misc-test.patch
- Disable drpm support
- Update to version 0.12.1:
* Release 0.12.1
* For make test, xz and zchunk (not just *-devel) are required.
* Make cmake variable PYTHON_EXECUTABLE global
* Add zchunk support already to Fedora 29
* [spec] Fix spec to work for epel 7
* Add CMake support for python interpreter path
* Add space after if statement
* Fix misc test
* Add missing sentinal
* Add zchunk support to mergerepo_c for extra files
-------------------------------------------------------------------
Mon Feb 4 12:09:27 UTC 2019 - Neal Gompa <ngompa13@gmail.com>
- Backport fixes from upstream
* 0001-zck_end_chunk-returns-number-of-bytes-written-or-1-f.patch
* 0002-Add-missing-sentinal.patch
* 0003-Fix-misc-test.patch
-------------------------------------------------------------------
Mon Feb 4 00:01:56 UTC 2019 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.12.0
+ Add basic support for zchunk metadata
+ Add support for building wheels to upload to PyPI
- Drop Python 2 subpackage
- Enable drpm support
- Enable zchunk for openSUSE Leap 15.1+ and Tumbleweed
- Adjust changes entries to use full author identities
-------------------------------------------------------------------
Wed Aug 1 12:06:35 UTC 2018 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.11.1
+ Add support for RPMs with large files
+ Identify Requires(missingok) as Recommends correctly
+ Enable legacy tags by default
+ Fix missing packages in mergerepo_c with multiple VR of same name
+ Add mergerepo_c --repo-prefix-search and --repo-prefix-replace
+ Build against Python 3 by default for bindings
- Drop snapshot source service and snapshot tarball
- Use license macro for license file
- Drop trailing whitespace
- Fix comment about drpm support
- [boo#1125044] fix for huge rpm packages
-------------------------------------------------------------------
Thu Apr 5 15:50:28 UTC 2018 - Adrian Schröter <adrian@suse.de>
- fix spelling of old weakdeps feature switch (bsc#1088328)
-------------------------------------------------------------------
Wed Feb 21 15:58:06 UTC 2018 - Frank Schreiner <FSchreiner@suse.com>
- [bnc#1075670] changed to provide createrepo as update-alternative
because createrepo_c will replace createrepo because of switch to
python3
- also provide createrepo-implementation
-------------------------------------------------------------------
Tue Feb 13 11:53:58 UTC 2018 - Tomáš Chvátal <tchvatal@suse.com>
- Disable tests on SLE12 due to the python-nose requirements
-------------------------------------------------------------------
Mon Jan 22 11:58:46 UTC 2018 - Tomáš Chvátal <tchvatal@suse.com>
- Switch to singlespec buidling of python bindings
- Make sure to use cmake macros to have it easier to gork what is
happending by overriding %__builddir
- Sort out with spec-cleaner
- Fix embedding of date and time to documentation
-------------------------------------------------------------------
Sun Feb 19 12:57:21 UTC 2017 - Neal Gompa <ngompa13@gmail.com>
- Enable Python bindings for openSUSE Leap.
-------------------------------------------------------------------
Sun Feb 19 02:27:30 UTC 2017 - Neal Gompa <ngompa13@gmail.com>
- Enable Python bindings for openSUSE Tumbleweed.
-------------------------------------------------------------------
Wed Feb 8 17:42:57 UTC 2017 - Neal Gompa <ngompa13@gmail.com>
- Updated upstream sources
- Removed patch 000-Ensure_that_provides-requires_versions_are_factored_into_dep_filtering.diff
(upstream included equal patch)
- Added missing copyright statements
- Fixed license tag and other misc cleanups
-------------------------------------------------------------------
Mon Oct 31 13:19:23 UTC 2016 - Frank Schreiner <FSchreiner@suse.com>
- updated upstream sources
- Added patch 000-Ensure_that_provides-requires_versions_are_factored_into_dep_filtering.diff
-------------------------------------------------------------------
Tue Jul 5 11:03:23 UTC 2016 - Jan Engelhardt <jengelh@inai.de>
- Run fdupes to eliminate duplicate .js files
-------------------------------------------------------------------
Mon Feb 1 04:49:43 UTC 2016 - Neal Gompa <ngompa13@gmail.com>
- Disable Python 3 bindings for SLE
-------------------------------------------------------------------
Mon Feb 1 04:40:40 UTC 2016 - Neal Gompa <ngompa13@gmail.com>
- Update to 0.10.0, add Python 3 bindings
-------------------------------------------------------------------
Thu Oct 29 14:48:00 UTC 2015 - Neal Gompa <ngompa13@gmail.com>
- Initial package based on Mageia package

271
createrepo_c.spec Normal file
View File

@ -0,0 +1,271 @@
#
# spec file for package createrepo_c
#
# Copyright (c) 2023 SUSE LLC
# Copyright (c) 2022 Neal Gompa <ngompa13@gmail.com>.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%{!?make_build: %global make_build make %{?_smp_mflags}}
%define major 1
%define libname lib%{name}%{major}
%define devname lib%{name}-devel
# prevent provides from nonstandard paths:
%global __provides_exclude ^(%{python3_sitearch}/.*\\.so)$
%if 0%{?suse_version} >= 1330
# Enable Python bindings on openSUSE
%bcond_without python3
%bcond_without tests
%else
%bcond_with python3
%bcond_with tests
%endif
%bcond_with drpm
%if 0%{?sle_version} >= 150100 || 0%{?suse_version} >= 1550
%bcond_without zchunk
%bcond_without libmodulemd
%else
%bcond_with zchunk
%bcond_with libmodulemd
%endif
%if 0%{?sle_version} && 0%{?sle_version} < 160000
%bcond_with as_createrepo
%else
%bcond_without as_createrepo
%endif
Name: createrepo_c
Version: 1.0.2
Release: 0
Summary: RPM repository metadata generation utility
License: GPL-2.0-or-later
Group: System/Packages
URL: https://github.com/rpm-software-management/createrepo_c
Source0: %{url}/archive/%{version}/%{name}-%{version}.tar.gz
BuildRequires: bash-completion
BuildRequires: cmake
BuildRequires: doxygen
BuildRequires: fdupes
BuildRequires: file-devel
BuildRequires: git-core
BuildRequires: glib2-devel >= 2.22.0
BuildRequires: libbz2-devel
BuildRequires: libcurl-devel
BuildRequires: libxml2-devel
BuildRequires: libzstd-devel
BuildRequires: lzma-devel
BuildRequires: openssl-devel
BuildRequires: rpm-devel >= 4.9.0
BuildRequires: sqlite3-devel
BuildRequires: zlib-devel
Requires: %{libname} = %{version}-%{release}
Requires: %{libname}%{?_isa} = %{version}-%{release}
Provides: createrepo-implementation
%if %{with python3}
BuildRequires: python3-devel
BuildRequires: python3-setuptools
%endif
%if 0%{?suse_version} >= 1330
BuildRequires: python-rpm-macros
%endif
%if %{with zchunk}
BuildRequires: zchunk
BuildRequires: zchunk-devel >= 0.9.11
%endif
%if %{with libmodulemd}
BuildRequires: libmodulemd-devel >= 2.3.0
%endif
%if %{with tests}
BuildRequires: python3
BuildRequires: python3-setuptools
%endif
%if 0%{?suse_version} >= 1330
BuildRequires: bash-completion-devel
%endif
%if %{with drpm}
BuildRequires: drpm-devel >= 0.4.0
%endif
%if %{with as_createrepo}
# Fully replaces createrepo
Requires(pre): update-alternatives
Obsoletes: createrepo < 0.11.0
Provides: createrepo = %{version}-%{release}
%else
Requires(post): update-alternatives
Requires(postun):update-alternatives
%endif
%description
C implementation of Createrepo.
A set of utilities (createrepo_c, mergerepo_c, modifyrepo_c)
for generating a common metadata repository from a directory of
rpm packages and maintaining it.
%package -n %{libname}
Summary: Library for repodata manipulation
Group: System/Libraries
%description -n %{libname}
Libraries for applications using the createrepo_c library
for easy manipulation with a repodata.
%package -n %{devname}
Summary: Library for repodata manipulation
Group: Development/Libraries/C and C++
Requires: %{libname}%{?_isa} = %{version}-%{release}
Requires: pkgconfig
Provides: %{name}-devel = %{version}-%{release}
%description -n %{devname}
This package contains the createrepo_c C library and header files.
These development files are for easy manipulation with a repodata.
%package -n python3-%{name}
Summary: Python 3 bindings for the createrepo_c library
Group: Development/Libraries/Python
Requires: %{libname}%{?_isa} = %{version}-%{release}
# Python 2 subpackage is fully dropped
Obsoletes: python2-%{name} < 0.12.0
%description -n python3-%{name}
The Python 3 bindings for the createrepo_c library.
%prep
%autosetup -S git_am
# do not hardcode date in the docs
sed -i -e '/HTML_TIMESTAMP/d' doc/Doxyfile.in.in
%build
%define __builddir build
%cmake \
%{!?with_zchunk:-DWITH_ZCHUNK=OFF} \
%{!?with_libmodulemd:-DWITH_LIBMODULEMD=OFF} \
%{!?with_drpm:-DENABLE_DRPM=OFF} \
%{!?with_python3:-DENABLE_PYTHON=OFF} \
-DENABLE_THREADED_XZ_ENCODER=OFF
%make_build
%make_build doc-c
%if %{with tests}
%check
%define __builddir build
%ctest
%endif
%install
%define __builddir build
%cmake_install
%if %{with as_createrepo}
for i in createrepo mergerepo modifyrepo sqliterepo;do
ln -s %{_bindir}/$i\_c %{buildroot}%{_bindir}/$i
echo ".so man8/$i\_c.8" > %{buildroot}%{_mandir}/man8/$i\.8
done
%else
mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for i in createrepo mergerepo modifyrepo sqliterepo;do
ln -s %{_bindir}/$i\_c %{buildroot}%{_sysconfdir}/alternatives/$i
ln -s %{_sysconfdir}/alternatives/$i %{buildroot}%{_bindir}/$i
ln -s %{_mandir}/man8/$i\_c.8.gz %{buildroot}%{_sysconfdir}/alternatives/$i\.8.gz
ln -s %{_sysconfdir}/alternatives/$i\.8.gz %{buildroot}%{_mandir}/man8/$i\.8.gz
done
%endif
%fdupes %{buildroot}%{_prefix}
%fdupes build/doc/html
%if %{with python3}
%python_compileall
%fdupes %{buildroot}%{python3_sitearch}
%endif
%if %{with as_createrepo}
%pre
if [ -e %{_sysconfdir}/alternatives/createrepo ]; then
update-alternatives --remove createrepo %{_bindir}/createrepo_c
fi
%else
%post
update-alternatives --install \
%{_bindir}/createrepo createrepo %{_bindir}/createrepo_c 20 \
--slave %{_bindir}/mergerepo mergerepo %{_bindir}/mergerepo_c \
--slave %{_bindir}/modifyrepo modifyrepo %{_bindir}/modifyrepo_c \
--slave %{_bindir}/sqliterepo sqliterepo %{_bindir}/sqliterepo_c \
--slave %{_mandir}/man8/createrepo.8.gz createrepo.8.gz %{_mandir}/man8/createrepo_c.8.gz \
--slave %{_mandir}/man8/mergerepo.8.gz mergerepo.8.gz %{_mandir}/man8/mergerepo_c.8.gz \
--slave %{_mandir}/man8/modifyrepo.8.gz modifyrepo.8.gz %{_mandir}/man8/modifyrepo_c.8.gz \
--slave %{_mandir}/man8/sqliterepo.8.gz sqliterepo.8.gz %{_mandir}/man8/sqliterepo_c.8.gz
%postun
if [ ! -f %{_bindir}/createrepo_c ]; then
update-alternatives --remove createrepo %{_bindir}/createrepo_c
fi
%endif
%post -n %{libname} -p /sbin/ldconfig
%postun -n %{libname} -p /sbin/ldconfig
%files
%doc README.md
%license COPYING
%{_mandir}/man8/createrepo_c.8%{?ext_man}
%{_mandir}/man8/mergerepo_c.8%{?ext_man}
%{_mandir}/man8/modifyrepo_c.8%{?ext_man}
%{_mandir}/man8/sqliterepo_c.8%{?ext_man}
%{_mandir}/man8/createrepo.8%{?ext_man}
%{_mandir}/man8/mergerepo.8%{?ext_man}
%{_mandir}/man8/modifyrepo.8%{?ext_man}
%{_mandir}/man8/sqliterepo.8%{?ext_man}
%{_datadir}/bash-completion/completions/
%{_bindir}/createrepo_c
%{_bindir}/mergerepo_c
%{_bindir}/modifyrepo_c
%{_bindir}/sqliterepo_c
%{_bindir}/createrepo
%{_bindir}/mergerepo
%{_bindir}/modifyrepo
%{_bindir}/sqliterepo
%if ! %{with as_createrepo}
%ghost %{_sysconfdir}/alternatives/createrepo
%ghost %{_sysconfdir}/alternatives/mergerepo
%ghost %{_sysconfdir}/alternatives/modifyrepo
%ghost %{_sysconfdir}/alternatives/sqliterepo
%ghost %{_sysconfdir}/alternatives/createrepo.8.gz
%ghost %{_sysconfdir}/alternatives/mergerepo.8.gz
%ghost %{_sysconfdir}/alternatives/modifyrepo.8.gz
%ghost %{_sysconfdir}/alternatives/sqliterepo.8.gz
%endif
%files -n %{libname}
%license COPYING
%{_libdir}/libcreaterepo_c.so.%{major}
%{_libdir}/libcreaterepo_c.so.%{major}.*
%files -n %{devname}
%doc build/doc/html
%license COPYING
%{_libdir}/libcreaterepo_c.so
%{_libdir}/pkgconfig/createrepo_c.pc
%{_includedir}/createrepo_c/
%if %{with python3}
%files -n python3-%{name}
%license COPYING
%{python3_sitearch}/createrepo_c/
%{python3_sitearch}/*egg-info
%endif
%changelog