5 %bcond_with rpm5 # build with rpm5, tests may fail (rpm.org vs rpm5 compat problems?)
6 %bcond_without tests # make tests
8 Summary: Creates a common metadata repository
9 Summary(pl.UTF-8): Tworzenie wspólnego repozytorium metadanych
14 Group: Applications/System
15 #Source0Download: https://github.com/rpm-software-management/createrepo_c/releases
16 Source0: https://github.com/rpm-software-management/createrepo_c/archive/%{version}/%{name}-%{version}.tar.gz
17 # Source0-md5: 7d9eda50ab16f4e004d7b6a608179346
18 Patch0: %{name}-rpm5.patch
19 URL: https://github.com/rpm-software-management/createrepo_c
20 BuildRequires: bzip2-devel
21 BuildRequires: check-devel
22 BuildRequires: cmake >= 2.6
23 BuildRequires: curl-devel
24 BuildRequires: doxygen
25 #BuildRequires: drpm-devel
26 BuildRequires: expat-devel
27 BuildRequires: glib2-devel >= 1:2.22.0
28 BuildRequires: libmagic-devel >= 5.40-2
29 BuildRequires: libxml2-devel >= 2
30 BuildRequires: openssl-devel
31 %{?with_tests:BuildRequires: python-nose}
32 BuildRequires: python3-devel >= 1:3.2
33 %{?with_tests:BuildRequires: python3-nose}
34 BuildRequires: rpm-devel
35 BuildRequires: rpm-pythonprov
36 BuildRequires: rpmbuild(macros) >= 1.673
37 BuildRequires: sphinx-pdg-2
38 BuildRequires: sqlite3-devel >= 3
39 BuildRequires: xz-devel
40 BuildRequires: zlib-devel
41 %{?with_tests:BuildRequires: zchunk}
42 Requires: %{name}-libs = %{version}-%{release}
43 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
46 C implementation of Createrepo. This utility will generate a common
47 metadata repository from a directory of RPM packages.
49 %description -l pl.UTF-8
50 Implementacja w C programu Createrepo. To narzędzie generuje wspólne
51 repozytorium metadanych z katalogu pakietów RPM.
54 Summary: Library for repodata manipulation
55 Summary(pl.UTF-8): Biblioteka do operacji na danych repozytorium
57 Requires: glib2 >= 1:2.22.0
60 This package contains the createrepo_c library for applications to
61 easy manipulate with a repodata.
63 %description libs -l pl.UTF-8
64 Ten pakiet zawiera bibliotekę createrepo_c, pozwalającą aplikacjom na
65 łatwe operowanie na danych repozytorium (repodata).
68 Summary: Header files for createrepo_c library
69 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki createrepo_c
70 Group: Development/Libraries
71 Requires: %{name}-libs = %{version}-%{release}
75 Requires: glib2-devel >= 1:2.22.0
76 Requires: libmagic-devel
77 Requires: libxml2-devel >= 2
79 Requires: sqlite3-devel >= 3
84 This package contains the createrepo_c C header files. These
85 development files are for easy manipulation with a repodata.
87 %description devel -l pl.UTF-8
88 Ten pakiet zawiera pliki nagłówkowe C biblioteki createrepo_c. Mają na
89 celu łatwe operowanie na danych repozytorium (repodata).
92 Summary: API documentation for createrepo_c library
93 Summary(pl.UTF-8): Dokumentacja API biblioteki createrepo_c
97 API documentation for createrepo_c library.
99 %description apidocs -l pl.UTF-8
100 Dokumentacja API biblioteki createrepo_c.
102 %package -n python3-createrepo_c
103 Summary: Python 3 bindings for the createrepo_c library
104 Summary(pl.UTF-8): Wiązania Pythona 3 do biblioteki createrepo_c
105 Group: Development/Languages/Python
106 Requires: %{name}-libs = %{version}-%{release}
107 Obsoletes: python-createrepo_c < 0.17.6
109 %description -n python3-createrepo_c
110 Python 3 bindings for the createrepo_c library.
112 %description -n python3-createrepo_c -l pl.UTF-8
113 Wiązania Pythona 3 do biblioteki createrepo_c.
115 %package -n bash-completion-createrepo_c
116 Summary: Bash completion for createrepo_c commands
117 Summary(pl.UTF-8): Bashowe uzupełnianie dla poleceń createrepo_c
118 Group: Applications/Shells
119 Requires: %{name} = %{version}-%{release}
120 Requires: bash-completion >= 2.0
122 %description -n bash-completion-createrepo_c
123 Bash completion for createrepo_c commands (createrepo_c, mergerepo_c,
126 %description -n bash-completion-createrepo_c -l pl.UTF-8
127 Bashowe uzupełnianie dla poleceń createrepo_c (createrepo_c,
128 mergerepo_c, modifyrepo_c).
132 %{?with_rpm5:%patch0 -p1}
138 -DBASHCOMP_DIR=%{bash_compdir} \
151 rm -rf $RPM_BUILD_ROOT
153 %{__make} -C build install \
154 DESTDIR=$RPM_BUILD_ROOT
155 %py3_comp $RPM_BUILD_ROOT%{py3_sitedir}/createrepo_c
156 %py3_ocomp $RPM_BUILD_ROOT%{py3_sitedir}/createrepo_c
159 rm -rf $RPM_BUILD_ROOT
161 %post libs -p /sbin/ldconfig
162 %postun libs -p /sbin/ldconfig
165 %defattr(644,root,root,755)
166 %attr(755,root,root) %{_bindir}/createrepo_c
167 %attr(755,root,root) %{_bindir}/mergerepo_c
168 %attr(755,root,root) %{_bindir}/modifyrepo_c
169 %attr(755,root,root) %{_bindir}/sqliterepo_c
170 %{_mandir}/man8/createrepo_c.8*
171 %{_mandir}/man8/mergerepo_c.8*
172 %{_mandir}/man8/modifyrepo_c.8*
173 %{_mandir}/man8/sqliterepo_c.8*
176 %defattr(644,root,root,755)
177 %doc AUTHORS README.md
178 %attr(755,root,root) %{_libdir}/libcreaterepo_c.so.*.*.*
179 %attr(755,root,root) %ghost %{_libdir}/libcreaterepo_c.so.0
182 %defattr(644,root,root,755)
183 %attr(755,root,root) %{_libdir}/libcreaterepo_c.so
184 %{_pkgconfigdir}/createrepo_c.pc
185 %{_includedir}/createrepo_c
188 %defattr(644,root,root,755)
191 %files -n python3-createrepo_c
192 %defattr(644,root,root,755)
193 %dir %{py3_sitedir}/createrepo_c
194 %attr(755,root,root) %{py3_sitedir}/createrepo_c/_createrepo_c.so
195 %{py3_sitedir}/createrepo_c/__init__.py
196 %{py3_sitedir}/createrepo_c/__pycache__
197 %{py3_sitedir}/createrepo_c-%{version}-py*.egg-info
199 %files -n bash-completion-createrepo_c
200 %defattr(644,root,root,755)
201 %{bash_compdir}/createrepo_c
202 %{bash_compdir}/mergerepo_c
203 %{bash_compdir}/modifyrepo_c
204 %{bash_compdir}/sqliterepo_c